Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion library/Icinga/File/Pdf.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
use Dompdf\Dompdf;
use Dompdf\Options;
use Exception;
use Icinga\Application\Hook;
use Icinga\Application\Hook\PdfexportHook;
use Icinga\Application\Icinga;
use Icinga\Exception\ProgrammingError;
Expand Down Expand Up @@ -56,7 +57,7 @@ public function renderControllerAction($controller)

$request = $controller->getRequest();

if (PdfexportHook::isRegistered()) {
if (Hook::has('Pdfexport')) {
$pdfexport = PdfexportHook::first();
$pdfexport->streamPdfFromHtml($html, sprintf(
'%s-%s-%d',
Expand Down
3 changes: 1 addition & 2 deletions library/Icinga/Web/Widget/Tabextension/OutputFormat.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@

namespace Icinga\Web\Widget\Tabextension;

use Icinga\Application\Hook\PdfexportHook;
use Icinga\Application\Platform;
use Icinga\Application\Hook;
use Icinga\Web\Url;
Expand Down Expand Up @@ -85,7 +84,7 @@ public function getSupportedTypes()
{
$supportedTypes = array();

$pdfexport = PdfexportHook::isRegistered();
$pdfexport = Hook::has('Pdfexport');

if ($pdfexport || Platform::extensionLoaded('gd')) {
$supportedTypes[self::TYPE_PDF] = array(
Expand Down
Loading