Fixed issues with deleting a image from gallery being delayed