@@ -68,8 +68,8 @@ discard block |
||
68 | 68 | private function getIsAdmin(HTTPRequest $request) |
69 | 69 | { |
70 | 70 | $adminPaths = static::config()->get('admin_url_paths'); |
71 | - $adminPaths[] = AdminRootController::config()->get('url_base') . '/'; |
|
72 | - $adminPaths[] = 'dev/'; |
|
71 | + $adminPaths[ ] = AdminRootController::config()->get('url_base') . '/'; |
|
72 | + $adminPaths[ ] = 'dev/'; |
|
73 | 73 | $currentPath = rtrim($request->getURL(), '/') . '/'; |
74 | 74 | foreach ($adminPaths as $adminPath) { |
75 | 75 | if (substr($currentPath, 0, strlen($adminPath)) === $adminPath) { |
@@ -81,7 +81,7 @@ discard block |
||
81 | 81 | |
82 | 82 | private function addBodyTag(&$response) |
83 | 83 | { |
84 | - $data = ArrayData::create(['GTMID' => $this->gtm_id]); |
|
84 | + $data = ArrayData::create([ 'GTMID' => $this->gtm_id ]); |
|
85 | 85 | $tag = $data->renderWith('BodySnippet'); |
86 | 86 | $body = $response->getBody(); |
87 | 87 | $pattern = '/\<body.*\>/'; |
@@ -92,7 +92,7 @@ discard block |
||
92 | 92 | |
93 | 93 | private function addHeadTag(&$response) |
94 | 94 | { |
95 | - $data = ArrayData::create(['GTMID' => $this->gtm_id]); |
|
95 | + $data = ArrayData::create([ 'GTMID' => $this->gtm_id ]); |
|
96 | 96 | $tag = $data->renderWith('HeadSnippet'); |
97 | 97 | $body = $response->getBody(); |
98 | 98 | $body = str_replace('<head>', "<head>" . $tag, $body); |