mirror of
https://github.com/element-hq/synapse.git
synced 2024-12-19 01:21:09 +03:00
Add m.encryption to event types
This commit is contained in:
parent
fd28d13e19
commit
3d0faa39fb
2 changed files with 3 additions and 1 deletions
|
@ -1,6 +1,7 @@
|
||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
# Copyright 2014-2016 OpenMarket Ltd
|
# Copyright 2014-2016 OpenMarket Ltd
|
||||||
# Copyright 2017 Vector Creations Ltd
|
# Copyright 2017 Vector Creations Ltd
|
||||||
|
# Copyright 2018 New Vector Ltd
|
||||||
#
|
#
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
# you may not use this file except in compliance with the License.
|
# you may not use this file except in compliance with the License.
|
||||||
|
@ -70,6 +71,7 @@ class EventTypes(object):
|
||||||
CanonicalAlias = "m.room.canonical_alias"
|
CanonicalAlias = "m.room.canonical_alias"
|
||||||
RoomAvatar = "m.room.avatar"
|
RoomAvatar = "m.room.avatar"
|
||||||
GuestAccess = "m.room.guest_access"
|
GuestAccess = "m.room.guest_access"
|
||||||
|
Encryption = "m.room.encryption"
|
||||||
|
|
||||||
# These are used for validation
|
# These are used for validation
|
||||||
Message = "m.room.message"
|
Message = "m.room.message"
|
||||||
|
|
|
@ -377,7 +377,7 @@ class RoomCreationHandler(BaseHandler):
|
||||||
|
|
||||||
if "encryption_alg" in config:
|
if "encryption_alg" in config:
|
||||||
send(
|
send(
|
||||||
etype="m.room.encryption",
|
etype=EventTypes.Encryption,
|
||||||
state_key="",
|
state_key="",
|
||||||
content={
|
content={
|
||||||
'algorithm': config["encryption_alg"],
|
'algorithm': config["encryption_alg"],
|
||||||
|
|
Loading…
Reference in a new issue