File tree Expand file tree Collapse file tree 2 files changed +7
-4
lines changed
library/Notifications/Hook Expand file tree Collapse file tree 2 files changed +7
-4
lines changed Original file line number Diff line number Diff line change 44
55namespace Icinga \Module \Notifications \Hook ;
66
7- use Exception ;
87use Generator ;
98use Icinga \Application \Hook ;
109use Icinga \Application \Logger ;
1615use ipl \Html \ValidHtml ;
1716use ipl \Web \Url ;
1817use ipl \Web \Widget \Link ;
18+ use Throwable ;
1919
2020/**
2121 * Base hook to prepare and render objects
@@ -178,7 +178,7 @@ function ($object) {
178178 }
179179 }
180180 }
181- } catch (Exception $ e ) {
181+ } catch (Throwable $ e ) {
182182 Logger::error ('Failed to load hook %s: ' , get_class ($ hook ), $ e );
183183 }
184184 }
@@ -289,7 +289,7 @@ final public static function renderObjectLink(Objects $object): ?ValidHtml
289289 ]
290290 ]);
291291 }
292- } catch (Exception $ e ) {
292+ } catch (Throwable $ e ) {
293293 Logger::error ('Failed to load hook %s: ' , get_class ($ hook ), $ e );
294294 }
295295 }
Original file line number Diff line number Diff line change 44
55/** @var \Icinga\Application\Modules\Module $this */
66
7- $ this ->provideHook ('Notifications/ObjectsRenderer ' );
7+ if ($ this ::exists ('icingadb ' )) {
8+ $ this ->provideHook ('Notifications/ObjectsRenderer ' );
9+ }
10+
811$ this ->provideHook ('authentication ' , 'SessionStorage ' , true );
912$ this ->addRoute (
1013 'static-file ' ,
You can’t perform that action at this time.
0 commit comments