Register add, refactor
This commit is contained in:
@@ -0,0 +1,21 @@
|
||||
# This folder should be used for working with the database
|
||||
# before I use dictionaries
|
||||
|
||||
from app.schemas.user import UserSchema
|
||||
from app.utils.bcrypt_utils import hash_password
|
||||
|
||||
john = UserSchema(
|
||||
username="john",
|
||||
password=hash_password("qwerty"),
|
||||
# email="john@example.com"
|
||||
)
|
||||
|
||||
sam = UserSchema(
|
||||
username="sam",
|
||||
password=hash_password("secret"),
|
||||
)
|
||||
|
||||
users_db: dict[str, UserSchema] = {
|
||||
john.username: john,
|
||||
sam.username: sam
|
||||
}
|
||||
Reference in New Issue
Block a user