#336: Fixed crash with array being modified
#336: Fixed crash with photos being null
#336: Fixed Fatal Exception NSRangeException