Commit c73d9a53 authored by jonnybradley's avatar jonnybradley

[FIX] sylv: Move the modifier include out of the "if comments added" statement...

[FIX] sylv: Move the modifier include out of the "if comments added" statement and replace with the smarty loadPlugin function (thanks Xavi)
parent ef0d59fa
......@@ -104,6 +104,8 @@ function module_since_last_visit_new($mod_reference, $params = null)
global $prefs;
$userlib = TikiLib::lib('user');
$tikilib = TikiLib::lib('tiki');
$smarty->loadPlugin('smarty_modifier_username');
$ret = array();
if ($params == null) {
$params = array();
......@@ -197,7 +199,6 @@ function module_since_last_visit_new($mod_reference, $params = null)
}
if ($visible) {
require_once('lib/smarty_tiki/modifier.username.php');
$ret['items']['comments']['list'][$count]['title'] = $tikilib->get_short_datetime($res['commentDate']) .' '. tra('by') .' '. smarty_modifier_username($res['userName']);
$ret['items']['comments']['list'][$count]['label'] = TikiLib::lib('comments')->process_comment_title($res, $params['commentlength']);;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment