Skip to content
Snippets Groups Projects
Unverified Commit 889bb44b authored by Roeland Jago Douma's avatar Roeland Jago Douma
Browse files

First query the server container


When the servercontainer wants to obtain something changes are very high
this is something from the server container. Esp on setups with a lot of
shares this can change quite a bit as it avoid a needless check on the
strpos OCA\\ etc.

Signed-off-by: default avatarRoeland Jago Douma <roeland@famdouma.nl>
parent a5fa9604
No related branches found
No related tags found
No related merge requests found
......@@ -133,6 +133,12 @@ class ServerContainer extends SimpleContainer {
public function query(string $name, bool $autoload = true) {
$name = $this->sanitizeName($name);
try {
return parent::query($name, false);
} catch (QueryException $e) {
// Continue with general autoloading then
}
// In case the service starts with OCA\ we try to find the service in
// the apps container first.
if (($appContainer = $this->getAppContainerForService($name)) !== null) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment