fix missing gallery thumbnails and navigation after adding photos
fix gallery thumbnail rotation issue