Rename PDB.register_user -> new_user.

I was treating User a little bit special here, but I prefer to
have the more consistent terminology.
This commit is contained in:
voussoir 2020-02-20 00:16:30 -08:00
parent 1fc2ed09f5
commit 854fa4db51
2 changed files with 2 additions and 2 deletions

View file

@ -1072,7 +1072,7 @@ class PDBUserMixin:
@decorators.required_feature('user.new')
@decorators.transaction
def register_user(self, username, password, *, display_name=None):
def new_user(self, username, password, *, display_name=None):
# These might raise exceptions.
self.assert_valid_username(username)

View file

@ -117,7 +117,7 @@ def post_register():
}
return jsonify.make_json_response(response, status=422)
user = common.P.register_user(username, password_1, display_name=display_name)
user = common.P.new_user(username, password_1, display_name=display_name)
session = sessions.Session(request, user)
session_manager.add(session)