remove pydantic from user.py
This commit is contained in:
@@ -1,5 +1,4 @@
|
||||
from pydantic import BaseModel
|
||||
|
||||
from dataclasses import dataclass, field
|
||||
from src.models import EncipheredNKode
|
||||
from src.customer_attributes import CustomerAttributes
|
||||
from src.user_cipher_keys import UserCipherKeys
|
||||
@@ -7,12 +6,13 @@ from src.user_interface import UserInterface
|
||||
from src.utils import xor_lists
|
||||
|
||||
|
||||
class User(BaseModel):
|
||||
@dataclass
|
||||
class User:
|
||||
username: str
|
||||
enciphered_passcode: EncipheredNKode
|
||||
user_keys: UserCipherKeys
|
||||
user_interface: UserInterface
|
||||
renew: bool = False
|
||||
renew: bool = field(default=False)
|
||||
|
||||
def renew_keys(self, sets_xor: list[int], attrs_xor: list[int]):
|
||||
self.renew = True
|
||||
|
||||
Reference in New Issue
Block a user