Applied patch from issue 25 (with minor edits)
Applied patch from issue 26
applied patch from issue 27 (added 'views' information to photo object)
Applied patch from issue 28