mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-12-15 15:18:47 -05:00
Add a make_event_from_dict method (#6858)
... and use it in places where it's trivial to do so. This will make it easier to pass room versions into the FrozenEvent constructors.
This commit is contained in:
parent
b08b0a22d5
commit
799001f2c0
13 changed files with 52 additions and 39 deletions
|
|
@ -15,7 +15,7 @@
|
|||
# limitations under the License.
|
||||
import logging
|
||||
|
||||
from synapse.events import FrozenEvent
|
||||
from synapse.events import make_event_from_dict
|
||||
from synapse.federation.federation_server import server_matches_acl_event
|
||||
from synapse.rest import admin
|
||||
from synapse.rest.client.v1 import login, room
|
||||
|
|
@ -105,7 +105,7 @@ class StateQueryTests(unittest.FederatingHomeserverTestCase):
|
|||
|
||||
|
||||
def _create_acl_event(content):
|
||||
return FrozenEvent(
|
||||
return make_event_from_dict(
|
||||
{
|
||||
"room_id": "!a:b",
|
||||
"event_id": "$a:b",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue