diff options
Diffstat (limited to 'lib/private/Activity/Manager.php')
-rw-r--r-- | lib/private/Activity/Manager.php | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/lib/private/Activity/Manager.php b/lib/private/Activity/Manager.php index 325f19bb7f1..cbe2d8c3eee 100644 --- a/lib/private/Activity/Manager.php +++ b/lib/private/Activity/Manager.php @@ -271,9 +271,11 @@ class Manager implements IManager { /** @var ISetting $setting */ $setting = \OC::$server->query($class); - if ($setting instanceof ISetting) { - $setting = new ActivitySettingsAdapter($setting); - } elseif (!$setting instanceof ActivitySettings) { + if (!$setting instanceof ISetting) { + if (!$setting instanceof ActivitySettings) { + $setting = new ActivitySettingsAdapter($setting); + } + } else { throw new \InvalidArgumentException('Invalid activity filter registered'); } |