mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-06-19 10:34:11 -04:00
Add type hints to synapse.events.*. (#11066)
Except `synapse/events/__init__.py`, which will be done in a follow-up.
This commit is contained in:
parent
cdd308845b
commit
1f9d0b8a7a
11 changed files with 208 additions and 145 deletions
|
@ -90,13 +90,13 @@ class EventBuilder:
|
|||
)
|
||||
|
||||
@property
|
||||
def state_key(self):
|
||||
def state_key(self) -> str:
|
||||
if self._state_key is not None:
|
||||
return self._state_key
|
||||
|
||||
raise AttributeError("state_key")
|
||||
|
||||
def is_state(self):
|
||||
def is_state(self) -> bool:
|
||||
return self._state_key is not None
|
||||
|
||||
async def build(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue