From cd0fbd47b08b99435f82ba3c9607b1b5bf04e8a9 Mon Sep 17 00:00:00 2001 From: Jean-Christian Denis Date: Thu, 8 Dec 2022 22:55:37 +0100 Subject: [PATCH] use dc methods for widget settings --- _widgets.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/_widgets.php b/_widgets.php index 411aa70..bc1a02c 100644 --- a/_widgets.php +++ b/_widgets.php @@ -118,7 +118,7 @@ class widgetKutrl if (!$s->kutrl_active || !$s->kutrl_srv_local_public - || ($w->homeonly == 1 && !dcCore::app()->url->isHome(dcCore::app()->url->type)) || ($w->homeonly == 2 && dcCore::app()->url->isHome(dcCore::app()->url->type)) + || !$w->checkHomeOnly(dcCore::app()->url->type) || dcCore::app()->url->type == 'kutrl') { return null; } @@ -153,8 +153,7 @@ class widgetKutrl { $s = dcCore::app()->blog->settings->kUtRL; - if (!$s->kutrl_active - || ($w->homeonly == 1 && !dcCore::app()->url->isHome(dcCore::app()->url->type)) || ($w->homeonly == 2 && dcCore::app()->url->isHome(dcCore::app()->url->type))) { + if (!$s->kutrl_active || !$w->checkHomeOnly(dcCore::app()->url->type)) { return null; }