]> granicus.if.org Git - ejabberd/commitdiff
Use correct field for oauth scope
authorPaweł Chmielowski <pchmielowski@process-one.net>
Thu, 6 Oct 2016 09:03:26 +0000 (11:03 +0200)
committerPaweł Chmielowski <pchmielowski@process-one.net>
Thu, 6 Oct 2016 09:03:26 +0000 (11:03 +0200)
src/ejabberd_access_permissions.erl

index 3b88e6ade6d49009bbeea875718f8339cc884e2b..766982a01d66c74c519bee439fd324e13c836b0f 100644 (file)
@@ -261,7 +261,7 @@ matches_definition({_Name, {From, Who, What}}, Cmd, Module, Host, CallerInfo) ->
        true ->
            case From == [] orelse lists:member(Module, From) of
                true ->
-                   Scope = maps:get(scope, CallerInfo, none),
+                   Scope = maps:get(oauth_scope, CallerInfo, none),
                    lists:any(
                        fun({access, Access}) when Scope == none ->
                            acl:access_matches(Access, CallerInfo, Host) == allow;