Rename function.
Fix comparison with None.
Use strict mode.
Remove existing field before adding new field.
Fix error handling.
Redo how rights are communicated.
Ensure you can remove photo action.
Display photo selected status correctly.
Another variable not declared.