From 1c585d2c502482624497f8e7d82a4f75f70c439c Mon Sep 17 00:00:00 2001 From: Robin Appelman Date: Mon, 9 Dec 2019 14:24:57 +0100 Subject: use OCP\EventDispatcher\GenericEvent in more places Signed-off-by: Robin Appelman --- lib/private/AppFramework/Middleware/AdditionalScriptsMiddleware.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'lib/private/AppFramework/Middleware') diff --git a/lib/private/AppFramework/Middleware/AdditionalScriptsMiddleware.php b/lib/private/AppFramework/Middleware/AdditionalScriptsMiddleware.php index 3ab084cd894..c65f8f8493a 100644 --- a/lib/private/AppFramework/Middleware/AdditionalScriptsMiddleware.php +++ b/lib/private/AppFramework/Middleware/AdditionalScriptsMiddleware.php @@ -29,6 +29,7 @@ use OCP\AppFramework\Http\StandaloneTemplateResponse; use OCP\AppFramework\Http\TemplateResponse; use OCP\AppFramework\Middleware; use OCP\AppFramework\PublicShareController; +use OCP\EventDispatcher\GenericEvent; use OCP\IUserSession; use Symfony\Component\EventDispatcher\EventDispatcherInterface; @@ -53,10 +54,10 @@ class AdditionalScriptsMiddleware extends Middleware { } if ($response instanceof TemplateResponse) { - $this->dispatcher->dispatch(TemplateResponse::EVENT_LOAD_ADDITIONAL_SCRIPTS); + $this->dispatcher->dispatch(TemplateResponse::EVENT_LOAD_ADDITIONAL_SCRIPTS, new GenericEvent()); if (!($response instanceof StandaloneTemplateResponse) && $this->userSession->isLoggedIn()) { - $this->dispatcher->dispatch(TemplateResponse::EVENT_LOAD_ADDITIONAL_SCRIPTS_LOGGEDIN); + $this->dispatcher->dispatch(TemplateResponse::EVENT_LOAD_ADDITIONAL_SCRIPTS_LOGGEDIN, new GenericEvent()); } } -- cgit v1.2.3