mirror of
https://github.com/stijndcl/didier.git
synced 2026-04-07 15:48:29 +02:00
fetching from db & dataclass
This commit is contained in:
parent
f6d06eb489
commit
3cfc87b7e1
4 changed files with 95 additions and 1 deletions
0
data/database_classes/__init__.py
Normal file
0
data/database_classes/__init__.py
Normal file
15
data/database_classes/custom_commands.py
Normal file
15
data/database_classes/custom_commands.py
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
from attr import dataclass
|
||||
|
||||
|
||||
@dataclass
|
||||
class CustomCommand:
|
||||
"""
|
||||
Class to store custom commands being triggered
|
||||
"""
|
||||
id: int = None
|
||||
name: str = None
|
||||
response: str = None
|
||||
alias_used: str = None
|
||||
|
||||
def __nonzero__(self):
|
||||
return self.id is not None
|
||||
Loading…
Add table
Add a link
Reference in a new issue