Passed
Pull Request — master (#173)
by Matthew
13:34
created
tests/objects/LocationTest.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -23,7 +23,7 @@
 block discarded – undo
23 23
     public function testGetCoords()
24 24
     {
25 25
         $location = $this->objFromFixture(Location::class, 'dynamic');
26
-        $coords = ((int)$location->Lat != 0 && (int)$location->Lng != 0) ? 'true' : 'false';
26
+        $coords = ((int) $location->Lat != 0 && (int) $location->Lng != 0) ? 'true' : 'false';
27 27
         $this->assertEquals($coords, $location->getCoords());
28 28
     }
29 29
 
Please login to merge, or discard this patch.
src/pages/LocatorController.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -53,7 +53,7 @@  discard block
 block discarded – undo
53 53
         parent::init();
54 54
 
55 55
         $key = Config::inst()->get(GoogleGeocoder::class, 'geocoder_api_key');
56
-        Requirements::javascript('https://maps.google.com/maps/api/js?key=' . $key);
56
+        Requirements::javascript('https://maps.google.com/maps/api/js?key='.$key);
57 57
     }
58 58
 
59 59
     public function json()
@@ -131,7 +131,7 @@  discard block
 block discarded – undo
131 131
 
132 132
         if ($request->getVar('address') && $request->getVar('radius')) {
133 133
             $radius = $request->getVar('radius');
134
-            $locations = $locations->filterByCallback(function ($location) use (&$radius) {
134
+            $locations = $locations->filterByCallback(function($location) use (&$radius) {
135 135
                 if ($radius === -1) {
136 136
                     return true;
137 137
                 }
Please login to merge, or discard this patch.
src/pages/Locator.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -82,7 +82,7 @@  discard block
 block discarded – undo
82 82
     public function getCMSFields()
83 83
     {
84 84
         // so it can easily be extended - concept taken from the blog module
85
-        $this->beforeUpdateCMSFields(function ($fields) {
85
+        $this->beforeUpdateCMSFields(function($fields) {
86 86
             // Settings
87 87
             $fields->addFieldsToTab('Root.Settings', array(
88 88
                 HeaderField::create('DisplayOptions', 'Display Options', 3),
@@ -226,7 +226,7 @@  discard block
 block discarded – undo
226 226
                 throw new \InvalidArgumentException("Can't find module '$module'");
227 227
             }
228 228
 
229
-            return Director::baseFolder() . '/' . $moduleObj->getRelativeResourcePath($resource);
229
+            return Director::baseFolder().'/'.$moduleObj->getRelativeResourcePath($resource);
230 230
         }
231 231
 
232 232
         return $file;
Please login to merge, or discard this patch.
src/objects/Location.php 2 patches
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -154,7 +154,7 @@  discard block
 block discarded – undo
154 154
             ));
155 155
 
156 156
             $fields->dataFieldByName('Website')
157
-                   ->setAttribute('placeholder', 'http://');
157
+                    ->setAttribute('placeholder', 'http://');
158 158
 
159 159
             $fields->replaceField('Email', EmailField::create('Email'));
160 160
 
@@ -164,7 +164,7 @@  discard block
 block discarded – undo
164 164
             );
165 165
 
166 166
             $featured = $fields->dataFieldByName('Featured')
167
-                               ->setDescription('Location will display near the top of the results list');
167
+                                ->setDescription('Location will display near the top of the results list');
168 168
             $fields->insertAfter(
169 169
                 $featured,
170 170
                 'CategoryID'
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -148,7 +148,7 @@
 block discarded – undo
148 148
     public function getCMSFields()
149 149
     {
150 150
         // so it can easily be extended - concept taken from the blog module
151
-        $this->beforeUpdateCMSFields(function ($fields) {
151
+        $this->beforeUpdateCMSFields(function($fields) {
152 152
             $fields->removeByName(array(
153 153
                 'Import_ID',
154 154
             ));
Please login to merge, or discard this patch.
src/bulkloader/LocationCsvBulkLoader.php 1 patch
Indentation   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -28,9 +28,9 @@
 block discarded – undo
28 28
      * @var array
29 29
      */
30 30
     public $relationCallbacks = array(
31
-       'Category.Name' => array(
32
-           'relationname' => 'Category',
33
-           'callback' => 'getCategoryByName',
31
+        'Category.Name' => array(
32
+            'relationname' => 'Category',
33
+            'callback' => 'getCategoryByName',
34 34
         ),
35 35
     );
36 36
 
Please login to merge, or discard this patch.