added photo type validation