def _format_content(password, salt, encrypt=True):
 if ((not encrypt) and (not salt)):
  return password
 assert salt, '_format_content was called with encryption requested but no salt value'
 return (u'%s salt=%s' % (password, salt))

def _format_content ( password , salt , encrypt = True ) : if ( ( not encrypt ) and ( not salt ) ) : return password assert salt , '_format_content was called with encryption requested but no salt value' return ( u'%s salt=%s' % ( password , salt ) )
format the password and salt for saving :arg password: the plaintext password to save :arg salt: the salt to use when encrypting a password :arg encrypt: whether the user requests that this password is encrypted .