Code Duplication    Length = 6-7 lines in 2 locations

viewtopic.php 1 location

@@ 463-468 (lines=6) @@
460
$xoopsTpl->assign_by_ref('admin_actions', $admin_actions);
461
$xoopsTpl->assign('viewer_level', (int)($isAdmin ? 2 : is_object($GLOBALS['xoopsUser'])));
462
463
if ($GLOBALS['xoopsModuleConfig']['show_permissiontable']) {
464
//    /** @var \NewbbPermissionHandler $permHandler */
465
//    $permHandler      = xoops_getModuleHandler('permission', 'newbb');
466
    $permission_table = $permHandler->getPermissionTable($forumObject, $topicObject->getVar('topic_status'), $isAdmin);
467
    $xoopsTpl->assign_by_ref('permission_table', $permission_table);
468
}
469
470
///////////////////////////////
471
// show Poll

viewforum.php 1 location

@@ 329-335 (lines=7) @@
326
    $xoopsTpl->assign('forum_jumpbox', newbbMakeJumpbox($forum_id));
327
}
328
329
if ($GLOBALS['xoopsModuleConfig']['show_permissiontable']) {
330
//    /** @var \NewbbPermissionHandler $permHandler */
331
//    $permHandler      = xoops_getModuleHandler('permission', 'newbb');
332
    $permission_table = $permHandler->getPermissionTable($forum_id, false, $isAdmin);
333
    $xoopsTpl->assign_by_ref('permission_table', $permission_table);
334
    unset($permission_table);
335
}
336
337
if (1 == $GLOBALS['xoopsModuleConfig']['rss_enable']) {
338
    $xoopsTpl->assign('rss_button', "<div align='right'><a href='" . XOOPS_URL . '/modules/' . $xoopsModule->dirname() . '/rss.php?f=' . $forum_id . "' title='RSS feed' target='_blank'>" . newbbDisplayImage('rss', 'RSS feed') . '</a></div>');