fix method handling for RPC_CALL_ADD
This event seems not to be used by any plugin, which explains why this bug hasn't surfaced yet. Access is always checked against a full method name in the form of plugin.<pluginname>.<method> Such a full method was not passed when using an event as described in the documentation.
This commit is contained in:
parent
dfe72b68b7
commit
f7acdb5eaf
|
@ -129,8 +129,9 @@ class Api
|
|||
if (!array_key_exists($method, $customCalls)) {
|
||||
throw new RemoteException('Method does not exist', -32603);
|
||||
}
|
||||
$customCall = $customCalls[$method];
|
||||
return $this->callPlugin($customCall[0], $customCall[1], $args);
|
||||
list($plugin, $method) = $customCalls[$method];
|
||||
$fullMethod = "plugin.$plugin.$method";
|
||||
return $this->callPlugin($plugin, $fullMethod, $args);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue