Passed
Push — develop ( 4abc61...39fefa )
by Jens
03:39
created
cloudcontrol/library/cc/Application.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -63,7 +63,7 @@  discard block
 block discarded – undo
63 63
 		 */
64 64
 		private function config()
65 65
 		{
66
-			$configPath = __DIR__ . '/../../config.json';
66
+			$configPath = __DIR__.'/../../config.json';
67 67
 			if (realpath($configPath) !== false) {
68 68
 				$json = file_get_contents($configPath);
69 69
 				$this->config = json_decode($json);
@@ -90,7 +90,7 @@  discard block
 block discarded – undo
90 90
 		private function sitemapMatching($request)
91 91
 		{
92 92
 			$sitemap = $this->storage->getSitemap()->getSitemap();
93
-			$relativeUri = '/' . $request::$relativeUri;
93
+			$relativeUri = '/'.$request::$relativeUri;
94 94
 
95 95
 			foreach ($sitemap as $sitemapItem) {
96 96
 				if ($sitemapItem->regex) {
@@ -153,17 +153,17 @@  discard block
 block discarded – undo
153 153
 		 * @return mixed
154 154
 		 * @throws \Exception
155 155
 		 */
156
-		private function getComponentObject($class='', $template='', $parameters=array(), $matchedSitemapItem)
156
+		private function getComponentObject($class = '', $template = '', $parameters = array(), $matchedSitemapItem)
157 157
 		{
158
-			$libraryComponentName = '\\library\\components\\' . $class;
159
-			$userComponentName = '\\components\\' . $class;
158
+			$libraryComponentName = '\\library\\components\\'.$class;
159
+			$userComponentName = '\\components\\'.$class;
160 160
 
161 161
 			if (AutoloadUtil::autoLoad($libraryComponentName, false)) {
162 162
 				$component = new $libraryComponentName($template, $this->request, $parameters, $matchedSitemapItem);
163 163
 			} elseif (AutoloadUtil::autoLoad($userComponentName, false)) {
164 164
 				$component = new $userComponentName($template, $this->request, $parameters, $matchedSitemapItem);
165 165
 			} else {
166
-				throw new \Exception('Could not load component ' . $class);
166
+				throw new \Exception('Could not load component '.$class);
167 167
 			}
168 168
 			
169 169
 			if (!$component instanceof Component) {
@@ -222,7 +222,7 @@  discard block
 block discarded – undo
222 222
 		public function setCachingHeaders()
223 223
 		{
224 224
 			header('Expires: '.gmdate('D, d M Y H:i:s \G\M\T', time() + (60 * 60 * 24 * 2))); // 2 days
225
-			header("Cache-Control: max-age=" . (60 * 60 * 24 * 2));
225
+			header("Cache-Control: max-age=".(60 * 60 * 24 * 2));
226 226
 		}
227 227
 
228 228
 		/**
Please login to merge, or discard this patch.
cloudcontrol/library/components/cms/SitemapRouting.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -57,7 +57,7 @@  discard block
 block discarded – undo
57 57
 		$cmsComponent->setParameter(CmsComponent::PARAMETER_MAIN_NAV_CLASS, CmsComponent::PARAMETER_SITEMAP);
58 58
 		if (isset($request::$post[CmsComponent::POST_PARAMETER_TITLE], $request::$post[CmsComponent::POST_PARAMETER_TEMPLATE], $request::$post[CmsComponent::POST_PARAMETER_COMPONENT])) {
59 59
 			$cmsComponent->storage->getSitemap()->addSitemapItem($request::$post);
60
-			header('Location: ' . $request::$subfolders . $cmsComponent->getParameter(CmsComponent::PARAMETER_CMS_PREFIX) . '/sitemap');
60
+			header('Location: '.$request::$subfolders.$cmsComponent->getParameter(CmsComponent::PARAMETER_CMS_PREFIX).'/sitemap');
61 61
 			exit;
62 62
 		}
63 63
 	}
@@ -73,7 +73,7 @@  discard block
 block discarded – undo
73 73
 		$sitemapItem = $cmsComponent->storage->getSitemap()->getSitemapItemBySlug($request::$get[CmsComponent::GET_PARAMETER_SLUG]);
74 74
 		if (isset($request::$post[CmsComponent::POST_PARAMETER_TITLE], $request::$post[CmsComponent::POST_PARAMETER_TEMPLATE], $request::$post[CmsComponent::POST_PARAMETER_COMPONENT])) {
75 75
 			$cmsComponent->storage->getSitemap()->saveSitemapItem($request::$get[CmsComponent::GET_PARAMETER_SLUG], $request::$post);
76
-			header('Location: ' . $request::$subfolders . $cmsComponent->getParameter(CmsComponent::PARAMETER_CMS_PREFIX) . '/sitemap');
76
+			header('Location: '.$request::$subfolders.$cmsComponent->getParameter(CmsComponent::PARAMETER_CMS_PREFIX).'/sitemap');
77 77
 			exit;
78 78
 		}
79 79
 		$cmsComponent->setParameter(CmsComponent::PARAMETER_SITEMAP_ITEM, $sitemapItem);
@@ -86,7 +86,7 @@  discard block
 block discarded – undo
86 86
 	private function deleteRoute($request, $cmsComponent)
87 87
 	{
88 88
 		$cmsComponent->storage->getSitemap()->deleteSitemapItemBySlug($request::$get[CmsComponent::GET_PARAMETER_SLUG]);
89
-		header('Location: ' . $request::$subfolders . $cmsComponent->getParameter(CmsComponent::PARAMETER_CMS_PREFIX) . '/sitemap');
89
+		header('Location: '.$request::$subfolders.$cmsComponent->getParameter(CmsComponent::PARAMETER_CMS_PREFIX).'/sitemap');
90 90
 		exit;
91 91
 	}
92 92
 }
93 93
\ No newline at end of file
Please login to merge, or discard this patch.