backout ability to pass in event type to server notices

This commit is contained in:
Neil Johnson 2018-08-14 13:32:56 +01:00
parent 9b75c78b4d
commit e2c9fe0a6a
3 changed files with 5 additions and 4 deletions

View file

@ -91,6 +91,7 @@ class ResourceLimitsServerNotices(object):
self._send_server_notice(user_id, content)
self._notified_of_blocking.add(user_id)
@defer.inlineCallbacks
def _send_server_notice(self, user_id, content):
"""Sends Server notice
@ -104,7 +105,7 @@ class ResourceLimitsServerNotices(object):
"""
try:
yield self._server_notices_manager.send_notice(
user_id, content, EventTypes.ServerNoticeLimitReached
user_id, content
)
except SynapseError as e:
logger.error("Error sending server notice about resource limits: %s", e)