bug fix for max photo size