Passed
Push — master ( 0e4096...7cb3ed )
by Nicolaas
02:58
created
code/model/translations/CountryPrice_Translation.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -100,7 +100,7 @@  discard block
 block discarded – undo
100 100
         $countryDropdownField = DropdownField::create(
101 101
             'EcommerceCountryID',
102 102
             $fields->dataFieldByName('EcommerceCountryID')->Title(),
103
-            array('' => '-- make sure to select a country --')+$countries
103
+            array('' => '-- make sure to select a country --') + $countries
104 104
         );
105 105
 
106 106
         // //$fields->removeFieldFromTab("Root.Main", 'ParentID');
@@ -133,7 +133,7 @@  discard block
 block discarded – undo
133 133
                 );
134 134
             }
135 135
             if ($fields->dataFieldByName($useField)) {
136
-                $fields->dataFieldByName($useField)->setDescription(_t('CountryPrice_Translation.IGNORE', 'Use untranslated value for ') . $dbField);
136
+                $fields->dataFieldByName($useField)->setDescription(_t('CountryPrice_Translation.IGNORE', 'Use untranslated value for ').$dbField);
137 137
             }
138 138
         }
139 139
         if ($this->exists() && $this->ParentID) {
@@ -166,12 +166,12 @@  discard block
 block discarded – undo
166 166
     {
167 167
         $validation = parent::validate();
168 168
         if ($validation->valid()) {
169
-            if (! $this->EcommerceCountryID) {
169
+            if (!$this->EcommerceCountryID) {
170 170
                 $validation->error(
171 171
                     'You can not create a translation without seleting a country.'
172 172
                 );
173 173
             }
174
-            if (! $this->ParentID) {
174
+            if (!$this->ParentID) {
175 175
                 $validation->error(
176 176
                     'You can not create a translation without attaching it to a page.'
177 177
                 );
@@ -221,7 +221,7 @@  discard block
 block discarded – undo
221 221
         );
222 222
         $this->extend('updateFieldsToReplace', $al);
223 223
         foreach ($al as $fieldToReplace) {
224
-            $ignoreField = 'UseOriginal' . $fieldToReplace->PageField;
224
+            $ignoreField = 'UseOriginal'.$fieldToReplace->PageField;
225 225
             if (!empty($this->owner->$ignoreField)) {
226 226
                 $al->remove($fieldToReplace);
227 227
             }
@@ -278,7 +278,7 @@  discard block
 block discarded – undo
278 278
                                     'ParentID' => $buyable->ID
279 279
                                 );
280 280
                                 $ecommerceCountries[$countryObject->ID] = $countryObject;
281
-                                if (! CountryPrice_Translation::get()->filter($filter)->first()) {
281
+                                if (!CountryPrice_Translation::get()->filter($filter)->first()) {
282 282
                                     DB::alteration_message(
283 283
                                         'Creating fake translation for '.$buyable->Title.' for country '.$countryObject->Code,
284 284
                                         'created'
@@ -299,7 +299,7 @@  discard block
 block discarded – undo
299 299
                             'EcommerceCountryID' => $countryObject->ID,
300 300
                             'ParentID' => $productGroup->ID
301 301
                         );
302
-                        if (! CountryPrice_Translation::get()->filter($filter)->first()) {
302
+                        if (!CountryPrice_Translation::get()->filter($filter)->first()) {
303 303
                             DB::alteration_message(
304 304
                                 'Creating fake translation for '.$productGroup->Title.' for country '.$countryObject->Code,
305 305
                                 'created'
Please login to merge, or discard this patch.