Optimized retrieving photos for relations
Renamed SimplePhotoModel to Photo
Some more optimizations