Code Duplication    Length = 6-6 lines in 3 locations

engine/classes/Elgg/Cache/ViewCacher.php 1 location

@@ 47-52 (lines=6) @@
44
45
			// Core view definitions in /engine/views.php
46
			$file = Paths::elgg() . 'engine/views.php';
47
			if (is_file($file)) {
48
				$spec = Includer::includeFile($file);
49
				if (is_array($spec)) {
50
					$this->views->mergeViewsSpec($spec);
51
				}
52
			}
53
		}
54
	}
55
}

engine/classes/Elgg/Application.php 1 location

@@ 326-331 (lines=6) @@
323
			if (!$config->system_cache_loaded) {
324
				// configure view locations for the custom plugin (not Elgg core)
325
				$viewsFile = Paths::project() . 'views.php';
326
				if (is_file($viewsFile)) {
327
					$viewsSpec = Includer::includeFile($viewsFile);
328
					if (is_array($viewsSpec)) {
329
						$this->_services->views->mergeViewsSpec($viewsSpec);
330
					}
331
				}
332
333
				// find views for the custom plugin (not Elgg core)
334
				$this->_services->views->registerPluginViews(Paths::project());

engine/classes/ElggPlugin.php 1 location

@@ 983-988 (lines=6) @@
980
981
		// Declared views first
982
		$file = "{$this->path}/views.php";
983
		if (is_file($file)) {
984
			$spec = Includer::includeFile($file);
985
			if (is_array($spec)) {
986
				$views->mergeViewsSpec($spec);
987
			}
988
		}
989
990
		$spec = $this->getStaticConfig('views');
991
		if ($spec) {