Use the constant

This commit is contained in:
David Baker 2016-04-29 19:10:45 +01:00
parent 29c8cf8db8
commit e7a76b5123
1 changed files with 2 additions and 1 deletions

View File

@ -27,6 +27,7 @@ from synapse.util.presentable_names import (
) )
from synapse.types import UserID from synapse.types import UserID
from synapse.api.errors import StoreError from synapse.api.errors import StoreError
from synapse.api.constants import EventTypes
import jinja2 import jinja2
import bleach import bleach
@ -209,7 +210,7 @@ class Mailer(object):
defer.returnValue(ret) defer.returnValue(ret)
def get_message_vars(self, notif, event, room_state): def get_message_vars(self, notif, event, room_state):
if event.type != "m.room.message": if event.type != EventTypes.Message:
return None return None
sender_state_event = room_state[("m.room.member", event.sender)] sender_state_event = room_state[("m.room.member", event.sender)]