Allow author to be an arbitrary field
All checks were successful
Build and Publish college-bot-v2 / build_and_publish (push) Successful in 15s
All checks were successful
Build and Publish college-bot-v2 / build_and_publish (push) Successful in 15s
This commit is contained in:
parent
3e37e38e79
commit
a9126fd123
1 changed files with 1 additions and 1 deletions
|
@ -22,7 +22,7 @@ class TruthPayload(BaseModel):
|
|||
"""Represents a truth. This can be used to both create and get truths."""
|
||||
id: str
|
||||
content: str
|
||||
author: typing.Literal["trump", "tate"] = Field(pattern=r"^(trump|tate)$")
|
||||
author: str
|
||||
timestamp: float = Field(default_factory=time.time, ge=0)
|
||||
extra: typing.Optional[JSON] = None
|
||||
"""Any extra information, JSON compliant, can be entered here."""
|
||||
|
|
Loading…
Reference in a new issue