Refactors photos controller
Small changes