From 90d570ead64fcc22de5ff6dd8f4a3b7c41f97d75 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Tim=20D=C3=BCsterhus?= Date: Tue, 16 Oct 2012 18:45:20 +0200 Subject: [PATCH] Removing DatediffModifier (duplicate of Date_D_iffModifier) Fixes #852 --- .../DatediffModifierTemplatePlugin.class.php | 41 ------------------- 1 file changed, 41 deletions(-) delete mode 100644 wcfsetup/install/files/lib/system/template/plugin/DatediffModifierTemplatePlugin.class.php diff --git a/wcfsetup/install/files/lib/system/template/plugin/DatediffModifierTemplatePlugin.class.php b/wcfsetup/install/files/lib/system/template/plugin/DatediffModifierTemplatePlugin.class.php deleted file mode 100644 index c3ac5dc9b5..0000000000 --- a/wcfsetup/install/files/lib/system/template/plugin/DatediffModifierTemplatePlugin.class.php +++ /dev/null @@ -1,41 +0,0 @@ - - * @package com.woltlab.wcf - * @subpackage system.template.plugin - * @category Community Framework - */ -class DateDiffModifierTemplatePlugin implements IModifierTemplatePlugin { - /** - * @see wcf\system\template\IModifierTemplatePlugin::execute() - */ - public function execute($tagArgs, TemplateEngine $tplObj) { - if (!isset($tagArgs[1])) { - $tagArgs[1] = TIME_NOW; - } - - $fullInterval = false; - if (isset($tagArgs[2])) { - $fullInterval = $tagArgs[2]; - } - - $startTime = DateUtil::getDateTimeByTimestamp(min($tagArgs[0], $tagArgs[1])); - $endTime = DateUtil::getDateTimeByTimestamp(max($tagArgs[0], $tagArgs[1])); - - return DateUtil::formatInterval($endTime->diff($startTime), $fullInterval); - } -} -- 2.20.1