GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

Code Duplication    Length = 35-35 lines in 2 locations

modules/module/module.model.php 2 locations

@@ 1366-1400 (lines=35) @@
1363
	 * @brief Return module configurations
1364
	 * Global configuration is used to manage board, member and others
1365
	 */
1366
	function getModuleConfig($module, $site_srl = 0)
1367
	{
1368
		$config = false;
1369
		// cache controll
1370
		$oCacheHandler = CacheHandler::getInstance('object', null, true);
1371
		if($oCacheHandler->isSupport())
1372
		{
1373
			$object_key = 'module_config:' . $module . '_' . $site_srl;
1374
			$cache_key = $oCacheHandler->getGroupKey('site_and_module', $object_key);
1375
			$config = $oCacheHandler->get($cache_key);
1376
		}
1377
1378
		if($config === false)
1379
		{
1380
			if(!$GLOBALS['__ModuleConfig__'][$site_srl][$module])
1381
			{
1382
				$args = new stdClass();
1383
				$args->module = $module;
1384
				$args->site_srl = $site_srl;
1385
				$output = executeQuery('module.getModuleConfig', $args);
1386
				if($output->data->config) $config = unserialize($output->data->config);
1387
				else $config = null;
1388
1389
				//insert in cache
1390
				if($oCacheHandler->isSupport())
1391
				{
1392
					$oCacheHandler->put($cache_key, $config);
1393
				}
1394
				$GLOBALS['__ModuleConfig__'][$site_srl][$module] = $config;
1395
			}
1396
			return $GLOBALS['__ModuleConfig__'][$site_srl][$module];
1397
		}
1398
1399
		return $config;
1400
	}
1401
1402
	/**
1403
	 * @brief Return the module configuration of mid
@@ 1406-1440 (lines=35) @@
1403
	 * @brief Return the module configuration of mid
1404
	 * Manage mid configurations which depend on module
1405
	 */
1406
	function getModulePartConfig($module, $module_srl)
1407
	{
1408
		$config = false;
1409
		// cache controll
1410
		$oCacheHandler = CacheHandler::getInstance('object', null, true);
1411
		if($oCacheHandler->isSupport())
1412
		{
1413
			$object_key = 'module_part_config:'.$module.'_'.$module_srl;
1414
			$cache_key = $oCacheHandler->getGroupKey('site_and_module', $object_key);
1415
			$config = $oCacheHandler->get($cache_key);
1416
		}
1417
1418
		if($config === false)
1419
		{
1420
			if(!isset($GLOBALS['__ModulePartConfig__'][$module][$module_srl]))
1421
			{
1422
				$args = new stdClass();
1423
				$args->module = $module;
1424
				$args->module_srl = $module_srl;
1425
				$output = executeQuery('module.getModulePartConfig', $args);
1426
				if($output->data->config) $config = unserialize($output->data->config);
1427
				else $config = null;
1428
1429
				//insert in cache
1430
				if($oCacheHandler->isSupport())
1431
				{
1432
					$oCacheHandler->put($cache_key, $config);
1433
				}
1434
				$GLOBALS['__ModulePartConfig__'][$module][$module_srl] = $config;
1435
			}
1436
			return $GLOBALS['__ModulePartConfig__'][$module][$module_srl];
1437
		}
1438
1439
		return $config;
1440
	}
1441
1442
	/**
1443
	 * @brief Get all of module configurations for each mid