From 9386b1b4cd339bba051d0834f12f0506cfa010d1 Mon Sep 17 00:00:00 2001 From: Jean-Christian Denis Date: Fri, 3 Sep 2021 21:35:13 +0200 Subject: [PATCH] enable other activity report system --- _prepend.php | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/_prepend.php b/_prepend.php index 854b1b7..c540d5e 100644 --- a/_prepend.php +++ b/_prepend.php @@ -20,18 +20,20 @@ $__autoload['activityReport'] = $d . 'class.activity.report.php'; $__autoload['activityReportBehaviors'] = $d . 'class.activity.report.behaviors.php'; try { - $core->activityReport = new activityReport($core); + if (!defined('ACTIVITY_REPORT')) { + $core->activityReport = new activityReport($core); - $core->url->register( - 'activityReport', - 'reports', - '^reports/((atom|rss2)/(.+))$', - ['activityReportPublicUrl', 'feed'] - ); + $core->url->register( + 'activityReport', + 'reports', + '^reports/((atom|rss2)/(.+))$', + ['activityReportPublicUrl', 'feed'] + ); - define('ACTIVITY_REPORT', true); + define('ACTIVITY_REPORT', true); - activityReportBehaviors::registerBehaviors($core); + activityReportBehaviors::registerBehaviors($core); + } } catch (Exception $e) { //throw new Exception('Failed to launch activityReport'); } \ No newline at end of file