diff options
author | David Baker <dave@matrix.org> | 2016-06-02 17:21:31 +0100 |
---|---|---|
committer | David Baker <dave@matrix.org> | 2016-06-02 17:21:31 +0100 |
commit | 1f31cc37f8611f9ae5612ef5be82e63735fbdf34 (patch) | |
tree | 20ac10037b1e13b61ed709ae665925fe53df6e46 /synapse/rest/client | |
parent | Merge remote-tracking branch 'origin/dbkr/email_notif_string_fmt_error' into ... (diff) | |
download | synapse-1f31cc37f8611f9ae5612ef5be82e63735fbdf34.tar.xz |
Working unsubscribe links going straight to the HS
and authed by macaroons that let you delete pushers and nothing else
Diffstat (limited to '')
-rw-r--r-- | synapse/rest/client/v1/pusher.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/synapse/rest/client/v1/pusher.py b/synapse/rest/client/v1/pusher.py index fa7a0992dd..9a2ed6ed88 100644 --- a/synapse/rest/client/v1/pusher.py +++ b/synapse/rest/client/v1/pusher.py @@ -149,11 +149,13 @@ class PushersRemoveRestServlet(RestServlet): def __init__(self, hs): super(RestServlet, self).__init__() + self.hs = hs self.notifier = hs.get_notifier() + self.auth = hs.get_v1auth() @defer.inlineCallbacks def on_GET(self, request): - requester = yield self.auth.get_user_by_req(request, "delete_pusher") + requester = yield self.auth.get_user_by_req(request, rights="delete_pusher") user = requester.user app_id = parse_string(request, "app_id", required=True) |