Code Duplication    Length = 4-4 lines in 2 locations

application/helpers/language_helper.php 1 location

@@ 275-278 (lines=4) @@
272
273
    $lang = $ci->db->get('languages')->result_array();
274
    $lan_array = [];
275
    foreach ($lang as $l) {
276
        $lan_array[$l['identif']] = $l['id'];
277
        $lan_array_rev[$l['id']] = $l['identif'];
278
    }
279
280
    $lang_uri = $ci->uri->segment(1);
281

application/modules/banners/banners.php 1 location

@@ 150-153 (lines=4) @@
147
148
        $lang = $this->db->get('languages')->result_array();
149
        $lan_array = [];
150
        foreach ($lang as $l) {
151
            $lan_array[$l['identif']] = $l['id'];
152
            $lan_array_rev[$l['id']] = $l['identif'];
153
        }
154
155
        $lang_uri = $this->uri->segment(1);
156
        if (in_array($lang_uri, $lan_array_rev)) {