Before, ~VulkanSurface() invokes a potentially empty std::function. Now, checks if it is empty before invoking it.