Code Duplication    Length = 4-4 lines in 2 locations

lib/private/legacy/util.php 2 locations

@@ 113-116 (lines=4) @@
110
111
		// instantiate object store implementation
112
		$name = $config['class'];
113
		if (strpos($name, 'OCA\\') === 0 && substr_count($name, '\\') >= 2) {
114
			$segments = explode('\\', $name);
115
			OC_App::loadApp(strtolower($segments[1]));
116
		}
117
		$config['arguments']['objectstore'] = new $config['class']($config['arguments']);
118
		// mount with plain / root object store implementation
119
		$config['class'] = '\OC\Files\ObjectStore\ObjectStoreStorage';
@@ 147-150 (lines=4) @@
144
145
		// instantiate object store implementation
146
		$name = $config['class'];
147
		if (strpos($name, 'OCA\\') === 0 && substr_count($name, '\\') >= 2) {
148
			$segments = explode('\\', $name);
149
			OC_App::loadApp(strtolower($segments[1]));
150
		}
151
152
		if (!isset($config['arguments']['bucket'])) {
153
			$config['arguments']['bucket'] = '';