mirror of
https://github.com/Noettore/lagomareGateKeeperBot.git
synced 2025-10-15 11:36:40 +02:00
Complete refactor... Some issue...
This commit is contained in:
32
commons.py
Normal file
32
commons.py
Normal file
@@ -0,0 +1,32 @@
|
||||
from enum import Enum
|
||||
|
||||
class Status(Enum):
|
||||
ENABLED = 1
|
||||
DISABLED = 0
|
||||
|
||||
class Credential:
|
||||
def __init__(self, username: str, password: str):
|
||||
self._username: str = username
|
||||
self._password: str = password
|
||||
|
||||
def __dict__(self):
|
||||
return {
|
||||
"username": self._username,
|
||||
"password": self._password
|
||||
}
|
||||
|
||||
@property
|
||||
def username(self) -> str:
|
||||
return self._username
|
||||
|
||||
@username.setter
|
||||
def username(self, username: str):
|
||||
self._username = username
|
||||
|
||||
@property
|
||||
def password(self) -> str:
|
||||
return self._password
|
||||
|
||||
@password.setter
|
||||
def password(self, password: str):
|
||||
self._password = password
|
Reference in New Issue
Block a user