comparison src/server/server.py @ 487:e588335b6aa8

browser and server side: force lower case for the profile name at new account creation + fixes CSS for textarea
author souliane <souliane@mailoo.org>
date Thu, 19 Jun 2014 19:28:17 +0200
parents 437eefa53a01
children 530c88c1deee
comparison
equal deleted inserted replaced
486:600a71743072 487:e588335b6aa8
672 - C.INTERNAL_ERROR or C.UNKNOWN_ERROR 672 - C.INTERNAL_ERROR or C.UNKNOWN_ERROR
673 - server.NOT_DONE_YET: the profile is being processed, the return 673 - server.NOT_DONE_YET: the profile is being processed, the return
674 value will be given later (one of those previously described) 674 value will be given later (one of those previously described)
675 """ 675 """
676 try: 676 try:
677 profile = login = request.args['register_login'][0] 677 # XXX: for now libervia forces the creation to lower case
678 profile = login = request.args['register_login'][0].lower()
678 password = request.args['register_password'][0] 679 password = request.args['register_password'][0]
679 email = request.args['email'][0] 680 email = request.args['email'][0]
680 except KeyError: 681 except KeyError:
681 return C.BAD_REQUEST 682 return C.BAD_REQUEST
682 if not re.match(r'^[a-z0-9_-]+$', login, re.IGNORECASE) or \ 683 if not re.match(r'^[a-z0-9_-]+$', login, re.IGNORECASE) or \