Add comment and error handling for plone password authentication code