Completed
Push — master ( 1f571c...0bd33c )
by Daniel
9s
created
code/MultiDomain.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -46,7 +46,7 @@
 block discarded – undo
46 46
      */
47 47
     public static function get_all_domains($includePrimary = false)
48 48
     {
49
-        $domains = array ();
49
+        $domains = array();
50 50
 
51 51
         foreach (self::config()->domains as $key => $config) {
52 52
             if (!$includePrimary && $key === self::KEY_PRIMARY) {
Please login to merge, or discard this patch.
code/MultiDomainDomain.php 1 patch
Spacing   +4 added lines, -5 removed lines patch added patch discarded remove patch
@@ -68,8 +68,8 @@  discard block
 block discarded – undo
68 68
 
69 69
         $globalAllowed = (array) Config::inst()->get('MultiDomain', 'allow');
70 70
         $globalForced = (array) Config::inst()->get('MultiDomain', 'force');
71
-        $myAllowed = isset($config['allow']) ? $config['allow'] : array ();
72
-        $myForced = isset($config['force']) ? $config['force'] : array ();
71
+        $myAllowed = isset($config['allow']) ? $config['allow'] : array();
72
+        $myForced = isset($config['force']) ? $config['force'] : array();
73 73
         $this->allowedPaths = array_merge($globalAllowed, $myAllowed);
74 74
         $this->forcedPaths = array_merge($globalForced, $myForced);
75 75
 
@@ -113,8 +113,7 @@  discard block
 block discarded – undo
113 113
         $hostname = $this->getHostname();
114 114
 
115 115
         return $allow_subdomains ?
116
-                    (bool) preg_match('/(\.|^)'.$hostname.'$/', $currentHost) :
117
-                    ($currentHost == $hostname);
116
+                    (bool) preg_match('/(\.|^)'.$hostname.'$/', $currentHost) : ($currentHost == $hostname);
118 117
     }
119 118
 
120 119
     /**
@@ -160,7 +159,7 @@  discard block
 block discarded – undo
160 159
         }
161 160
 
162 161
         $domainUrl = str_replace('/', '\/', $this->getURL());
163
-        return preg_replace('/^\/?' . $domainUrl . '\//', '', $url);
162
+        return preg_replace('/^\/?'.$domainUrl.'\//', '', $url);
164 163
     }
165 164
 
166 165
     /**
Please login to merge, or discard this patch.