Code Duplication    Length = 12-12 lines in 2 locations

htdocs/kernel/notification.php 2 locations

@@ 693-704 (lines=12) @@
690
        $not_config = $module->getInfo('notification');
691
        $tags       = array();
692
        if (!empty($not_config)) {
693
            if (!empty($not_config['tags_file'])) {
694
                $tags_file = $GLOBALS['xoops']->path('modules/' . $module->getVar('dirname') . '/' . $not_config['tags_file']);
695
                if (file_exists($tags_file)) {
696
                    include_once $tags_file;
697
                    if (!empty($not_config['tags_func'])) {
698
                        $tags_func = $not_config['tags_func'];
699
                        if (function_exists($tags_func)) {
700
                            $tags = $tags_func($category, (int)$item_id, $event);
701
                        }
702
                    }
703
                }
704
            }
705
            // RMV-NEW
706
            if (!empty($not_config['lookup_file'])) {
707
                $lookup_file = $GLOBALS['xoops']->path('modules/' . $module->getVar('dirname') . '/' . $not_config['lookup_file']);
@@ 706-717 (lines=12) @@
703
                }
704
            }
705
            // RMV-NEW
706
            if (!empty($not_config['lookup_file'])) {
707
                $lookup_file = $GLOBALS['xoops']->path('modules/' . $module->getVar('dirname') . '/' . $not_config['lookup_file']);
708
                if (file_exists($lookup_file)) {
709
                    include_once $lookup_file;
710
                    if (!empty($not_config['lookup_func'])) {
711
                        $lookup_func = $not_config['lookup_func'];
712
                        if (function_exists($lookup_func)) {
713
                            $item_info = $lookup_func($category, (int)$item_id);
714
                        }
715
                    }
716
                }
717
            }
718
        }
719
        $tags['X_ITEM_NAME']       = !empty($item_info['name']) ? $item_info['name'] : '[' . _NOT_ITEMNAMENOTAVAILABLE . ']';
720
        $tags['X_ITEM_URL']        = !empty($item_info['url']) ? $item_info['url'] : '[' . _NOT_ITEMURLNOTAVAILABLE . ']';