Code Duplication    Length = 4-4 lines in 2 locations

core/SanityTests.php 2 locations

@@ 357-360 (lines=4) @@
354
                $this->test_return(\core\common\Entity::L_REMARK, "PHP extension <strong>GeoIP</strong> (legacy) is installed and working. See utils/GeoIP-update.sh in the CAT distribution and use it tu update the GeoIP database regularly. We stronly advise to replace the legacy GeoIP with GeoIP2 from <a href='https://github.com/maxmind/GeoIP2-php'>here</a>.");
355
                break;
356
            case 2:
357
                if (!is_file(CONFIG['GEOIP']['geoip2-path-to-autoloader'])) {
358
                    $this->test_return(\core\common\Entity::L_ERROR, "PHP extension <strong>GeoIP2</strong> not found! Get it from <a href='https://github.com/maxmind/GeoIP2-php'>here</a>.");
359
                    return;
360
                }
361
                if (!is_file(CONFIG['GEOIP']['geoip2-path-to-db'])) {
362
                    $this->test_return(\core\common\Entity::L_ERROR, "<strong>GeoIP2 database</strong> not found! See utils/GeoIP-update.sh in the CAT distribution and use it tu update the GeoIP database regularly.");
363
                    return;
@@ 361-364 (lines=4) @@
358
                    $this->test_return(\core\common\Entity::L_ERROR, "PHP extension <strong>GeoIP2</strong> not found! Get it from <a href='https://github.com/maxmind/GeoIP2-php'>here</a>.");
359
                    return;
360
                }
361
                if (!is_file(CONFIG['GEOIP']['geoip2-path-to-db'])) {
362
                    $this->test_return(\core\common\Entity::L_ERROR, "<strong>GeoIP2 database</strong> not found! See utils/GeoIP-update.sh in the CAT distribution and use it tu update the GeoIP database regularly.");
363
                    return;
364
                }
365
                require_once CONFIG['GEOIP']['geoip2-path-to-autoloader'];
366
                $reader = new Reader(CONFIG['GEOIP']['geoip2-path-to-db']);
367
                try {