Пример #1
0
 def register(cls, username, pw, email = None):
     pw_hash = hashing.make_pw_hash(username, pw)
     return User(parent = hashing.users_key(),
                 username = username,
                 password = pw_hash,
                 email = email)
Пример #2
0
 def by_id(cls, uid):
     return cls.get_by_id(uid, parent = hashing.users_key())