Photo upload thumbnail generation bug fix, photo deletion