Passed
Push — master ( 50e989...69e622 )
by Aimeos
05:21
created
lib/mshoplib/setup/unittest/CustomerAddTestData.php 2 patches
Braces   +6 added lines, -2 removed lines patch added patch discarded remove patch
@@ -205,9 +205,13 @@
 block discarded – undo
205 205
 			$group->setCode( $dataset['code'] );
206 206
 			$group->setLabel( $dataset['label'] );
207 207
 
208
-			try {
208
+			try
209
+			{
209 210
 				$customerGroupManager->saveItem( $group, false );
210
-			} catch( \Exception $e ) { ; } // ignore duplicates
211
+			}
212
+			catch( \Exception $e )
213
+			{
214
+; } // ignore duplicates
211 215
 		}
212 216
 	}
213 217
 }
214 218
\ No newline at end of file
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -208,7 +208,7 @@
 block discarded – undo
208 208
 
209 209
 			try {
210 210
 				$customerGroupManager->saveItem( $group, false );
211
-			} catch( \Exception $e ) { ; } // ignore duplicates
211
+			} catch( \Exception $e ) {; } // ignore duplicates
212 212
 		}
213 213
 	}
214 214
 }
215 215
\ No newline at end of file
Please login to merge, or discard this patch.
lib/mshoplib/setup/MShopAddTypeData.php 2 patches
Braces   +6 added lines, -2 removed lines patch added patch discarded remove patch
@@ -100,10 +100,14 @@
 block discarded – undo
100 100
 				$type->setLabel( $dataset['label'] );
101 101
 				$type->setStatus( $dataset['status'] );
102 102
 
103
-				try {
103
+				try
104
+				{
104 105
 					$domainManager->saveItem( $type );
105 106
 					$num++;
106
-				} catch( \Exception $e ) { ; } // if type was already available
107
+				}
108
+				catch( \Exception $e )
109
+				{
110
+; } // if type was already available
107 111
 			}
108 112
 
109 113
 			$this->status( $num > 0 ? $num . '/' . $total : 'OK' );
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -100,7 +100,7 @@
 block discarded – undo
100 100
 				try {
101 101
 					$domainManager->saveItem( $type );
102 102
 					$num++;
103
-				} catch( \Exception $e ) { ; } // if type was already available
103
+				} catch( \Exception $e ) {; } // if type was already available
104 104
 			}
105 105
 
106 106
 			$this->status( $num > 0 ? $num . '/' . $total : 'OK' );
Please login to merge, or discard this patch.
lib/mwlib/tests/MW/View/Helper/Access/StandardTest.php 1 patch
Braces   +12 added lines, -4 removed lines patch added patch discarded remove patch
@@ -14,7 +14,9 @@  discard block
 block discarded – undo
14 14
 	public function testTransformSingleOK()
15 15
 	{
16 16
 		$view = new \Aimeos\MW\View\Standard();
17
-		$fcn = function() { return array( 'editor' ); };
17
+		$fcn = function()
18
+		{
19
+return array( 'editor' ); };
18 20
 
19 21
 		$object = new \Aimeos\MW\View\Helper\Access\Standard( $view, $fcn );
20 22
 		$this->assertTrue( $object->transform( 'editor' ) );
@@ -24,7 +26,9 @@  discard block
 block discarded – undo
24 26
 	public function testTransformSingleFailure()
25 27
 	{
26 28
 		$view = new \Aimeos\MW\View\Standard();
27
-		$fcn = function() { return array( 'editor' ); };
29
+		$fcn = function()
30
+		{
31
+return array( 'editor' ); };
28 32
 
29 33
 		$object = new \Aimeos\MW\View\Helper\Access\Standard( $view, $fcn );
30 34
 		$this->assertFalse( $object->transform( 'admin' ) );
@@ -34,7 +38,9 @@  discard block
 block discarded – undo
34 38
 	public function testTransformMultipleOK()
35 39
 	{
36 40
 		$view = new \Aimeos\MW\View\Standard();
37
-		$fcn = function() { return array( 'admin', 'editor' ); };
41
+		$fcn = function()
42
+		{
43
+return array( 'admin', 'editor' ); };
38 44
 
39 45
 		$object = new \Aimeos\MW\View\Helper\Access\Standard( $view, $fcn );
40 46
 		$this->assertTrue( $object->transform( array( 'editor' ) ) );
@@ -44,7 +50,9 @@  discard block
 block discarded – undo
44 50
 	public function testTransformMultipleFailure()
45 51
 	{
46 52
 		$view = new \Aimeos\MW\View\Standard();
47
-		$fcn = function() { return array( 'admin', 'editor' ); };
53
+		$fcn = function()
54
+		{
55
+return array( 'admin', 'editor' ); };
48 56
 
49 57
 		$object = new \Aimeos\MW\View\Helper\Access\Standard( $view, $fcn );
50 58
 		$this->assertFalse( $object->transform( array( 'test', 'example' ) ) );
Please login to merge, or discard this patch.
lib/mshoplib/setup/OrderAddTimes.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -161,7 +161,7 @@
 block discarded – undo
161 161
 
162 162
 				$stmt->bind( 1, $date );
163 163
 				$stmt->bind( 2, substr( $date, 0, 7 ) );
164
-				$stmt->bind( 3, date_create_from_format( 'Y-m-d', $date )->format( 'Y-W' )  );
164
+				$stmt->bind( 3, date_create_from_format( 'Y-m-d', $date )->format( 'Y-W' ) );
165 165
 				$stmt->bind( 4, substr( $time, 0, 2 ) );
166 166
 				$stmt->bind( 5, $id, \Aimeos\MW\DB\Statement\Base::PARAM_INT );
167 167
 
Please login to merge, or discard this patch.
lib/mshoplib/setup/default/schema/order.php 2 patches
Braces   +18 added lines, -9 removed lines patch added patch discarded remove patch
@@ -16,7 +16,8 @@  discard block
 block discarded – undo
16 16
 
17 17
 	'table' => array(
18 18
 
19
-		'mshop_order_base' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
19
+		'mshop_order_base' => function ( \Doctrine\DBAL\Schema\Schema $schema )
20
+		{
20 21
 
21 22
 			$table = $schema->createTable( 'mshop_order_base' );
22 23
 
@@ -45,7 +46,8 @@  discard block
 block discarded – undo
45 46
 			return $schema;
46 47
 		},
47 48
 
48
-		'mshop_order_base_address' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
49
+		'mshop_order_base_address' => function ( \Doctrine\DBAL\Schema\Schema $schema )
50
+		{
49 51
 
50 52
 			$table = $schema->createTable( 'mshop_order_base_address' );
51 53
 
@@ -93,7 +95,8 @@  discard block
 block discarded – undo
93 95
 			return $schema;
94 96
 		},
95 97
 
96
-		'mshop_order_base_product' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
98
+		'mshop_order_base_product' => function ( \Doctrine\DBAL\Schema\Schema $schema )
99
+		{
97 100
 
98 101
 			$table = $schema->createTable( 'mshop_order_base_product' );
99 102
 
@@ -134,7 +137,8 @@  discard block
 block discarded – undo
134 137
 			return $schema;
135 138
 		},
136 139
 
137
-		'mshop_order_base_product_attr' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
140
+		'mshop_order_base_product_attr' => function ( \Doctrine\DBAL\Schema\Schema $schema )
141
+		{
138 142
 
139 143
 			$table = $schema->createTable( 'mshop_order_base_product_attr' );
140 144
 
@@ -160,7 +164,8 @@  discard block
 block discarded – undo
160 164
 			return $schema;
161 165
 		},
162 166
 
163
-		'mshop_order_base_service' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
167
+		'mshop_order_base_service' => function ( \Doctrine\DBAL\Schema\Schema $schema )
168
+		{
164 169
 
165 170
 			$table = $schema->createTable( 'mshop_order_base_service' );
166 171
 
@@ -194,7 +199,8 @@  discard block
 block discarded – undo
194 199
 			return $schema;
195 200
 		},
196 201
 
197
-		'mshop_order_base_service_attr' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
202
+		'mshop_order_base_service_attr' => function ( \Doctrine\DBAL\Schema\Schema $schema )
203
+		{
198 204
 
199 205
 			$table = $schema->createTable( 'mshop_order_base_service_attr' );
200 206
 
@@ -220,7 +226,8 @@  discard block
 block discarded – undo
220 226
 			return $schema;
221 227
 		},
222 228
 
223
-		'mshop_order_base_coupon' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
229
+		'mshop_order_base_coupon' => function ( \Doctrine\DBAL\Schema\Schema $schema )
230
+		{
224 231
 
225 232
 			$table = $schema->createTable( 'mshop_order_base_coupon' );
226 233
 
@@ -247,7 +254,8 @@  discard block
 block discarded – undo
247 254
 			return $schema;
248 255
 		},
249 256
 
250
-		'mshop_order' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
257
+		'mshop_order' => function ( \Doctrine\DBAL\Schema\Schema $schema )
258
+		{
251 259
 
252 260
 			$table = $schema->createTable( 'mshop_order' );
253 261
 
@@ -289,7 +297,8 @@  discard block
 block discarded – undo
289 297
 			return $schema;
290 298
 		},
291 299
 
292
-		'mshop_order_status' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
300
+		'mshop_order_status' => function ( \Doctrine\DBAL\Schema\Schema $schema )
301
+		{
293 302
 
294 303
 			$table = $schema->createTable( 'mshop_order_status' );
295 304
 
Please login to merge, or discard this patch.
Spacing   +20 added lines, -20 removed lines patch added patch discarded remove patch
@@ -16,7 +16,7 @@  discard block
 block discarded – undo
16 16
 
17 17
 	'table' => array(
18 18
 
19
-		'mshop_order_base' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
19
+		'mshop_order_base' => function( \Doctrine\DBAL\Schema\Schema $schema ) {
20 20
 
21 21
 			$table = $schema->createTable( 'mshop_order_base' );
22 22
 
@@ -35,7 +35,7 @@  discard block
 block discarded – undo
35 35
 			$table->addColumn( 'status', 'smallint', [] );
36 36
 			$table->addColumn( 'mtime', 'datetime', [] );
37 37
 			$table->addColumn( 'ctime', 'datetime', [] );
38
-			$table->addColumn( 'editor', 'string', array('length' => 255 ) );
38
+			$table->addColumn( 'editor', 'string', array( 'length' => 255 ) );
39 39
 
40 40
 			$table->setPrimaryKey( array( 'id' ), 'pk_msordba_id' );
41 41
 			$table->addIndex( array( 'sitecode', 'customerid' ), 'idx_msordba_scode_custid' );
@@ -45,7 +45,7 @@  discard block
 block discarded – undo
45 45
 			return $schema;
46 46
 		},
47 47
 
48
-		'mshop_order_base_address' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
48
+		'mshop_order_base_address' => function( \Doctrine\DBAL\Schema\Schema $schema ) {
49 49
 
50 50
 			$table = $schema->createTable( 'mshop_order_base_address' );
51 51
 
@@ -76,7 +76,7 @@  discard block
 block discarded – undo
76 76
 			$table->addColumn( 'latitude', 'decimal', array( 'precision' => 8, 'scale' => 6, 'notnull' => false ) );
77 77
 			$table->addColumn( 'mtime', 'datetime', [] );
78 78
 			$table->addColumn( 'ctime', 'datetime', [] );
79
-			$table->addColumn( 'editor', 'string', array('length' => 255 ) );
79
+			$table->addColumn( 'editor', 'string', array( 'length' => 255 ) );
80 80
 
81 81
 			$table->setPrimaryKey( array( 'id' ), 'pk_msordbaad_id' );
82 82
 			$table->addUniqueIndex( array( 'baseid', 'type' ), 'unq_msordbaad_bid_type' );
@@ -94,7 +94,7 @@  discard block
 block discarded – undo
94 94
 			return $schema;
95 95
 		},
96 96
 
97
-		'mshop_order_base_product' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
97
+		'mshop_order_base_product' => function( \Doctrine\DBAL\Schema\Schema $schema ) {
98 98
 
99 99
 			$table = $schema->createTable( 'mshop_order_base_product' );
100 100
 
@@ -104,8 +104,8 @@  discard block
 block discarded – undo
104 104
 			$table->addColumn( 'ordprodid', 'bigint', array( 'notnull' => false ) );
105 105
 			$table->addColumn( 'type', 'string', array( 'length' => 32 ) );
106 106
 			$table->addColumn( 'prodid', 'string', array( 'length' => 32 ) );
107
-			$table->addColumn( 'prodcode', 'string', array( 'length' => 32  ) );
108
-			$table->addColumn( 'suppliercode', 'string', array( 'length' => 32  ) );
107
+			$table->addColumn( 'prodcode', 'string', array( 'length' => 32 ) );
108
+			$table->addColumn( 'suppliercode', 'string', array( 'length' => 32 ) );
109 109
 			$table->addColumn( 'stocktype', 'string', array( 'length' => 32 ) );
110 110
 			$table->addColumn( 'name', 'text', array( 'length' => 0xffff ) );
111 111
 			$table->addColumn( 'mediaurl', 'string', array( 'length' => 255 ) );
@@ -123,7 +123,7 @@  discard block
 block discarded – undo
123 123
 			$table->addColumn( 'status', 'smallint', array( 'default' => -1 ) );
124 124
 			$table->addColumn( 'mtime', 'datetime', [] );
125 125
 			$table->addColumn( 'ctime', 'datetime', [] );
126
-			$table->addColumn( 'editor', 'string', array('length' => 255 ) );
126
+			$table->addColumn( 'editor', 'string', array( 'length' => 255 ) );
127 127
 
128 128
 			$table->setPrimaryKey( array( 'id' ), 'pk_msordbapr_id' );
129 129
 			$table->addUniqueIndex( array( 'baseid', 'pos' ), 'unq_msordbapr_bid_pos' );
@@ -137,7 +137,7 @@  discard block
 block discarded – undo
137 137
 			return $schema;
138 138
 		},
139 139
 
140
-		'mshop_order_base_product_attr' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
140
+		'mshop_order_base_product_attr' => function( \Doctrine\DBAL\Schema\Schema $schema ) {
141 141
 
142 142
 			$table = $schema->createTable( 'mshop_order_base_product_attr' );
143 143
 
@@ -152,7 +152,7 @@  discard block
 block discarded – undo
152 152
 			$table->addColumn( 'quantity', 'integer', [] );
153 153
 			$table->addColumn( 'mtime', 'datetime', [] );
154 154
 			$table->addColumn( 'ctime', 'datetime', [] );
155
-			$table->addColumn( 'editor', 'string', array('length' => 255 ) );
155
+			$table->addColumn( 'editor', 'string', array( 'length' => 255 ) );
156 156
 
157 157
 			$table->setPrimaryKey( array( 'id' ), 'pk_msordbaprat_id' );
158 158
 			$table->addUniqueIndex( array( 'ordprodid', 'attrid', 'type', 'code' ), 'unq_msordbaprat_oid_aid_ty_cd' );
@@ -164,7 +164,7 @@  discard block
 block discarded – undo
164 164
 			return $schema;
165 165
 		},
166 166
 
167
-		'mshop_order_base_service' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
167
+		'mshop_order_base_service' => function( \Doctrine\DBAL\Schema\Schema $schema ) {
168 168
 
169 169
 			$table = $schema->createTable( 'mshop_order_base_service' );
170 170
 
@@ -185,7 +185,7 @@  discard block
 block discarded – undo
185 185
 			$table->addColumn( 'taxflag', 'smallint', [] );
186 186
 			$table->addColumn( 'mtime', 'datetime', [] );
187 187
 			$table->addColumn( 'ctime', 'datetime', [] );
188
-			$table->addColumn( 'editor', 'string', array('length' => 255 ) );
188
+			$table->addColumn( 'editor', 'string', array( 'length' => 255 ) );
189 189
 
190 190
 			$table->setPrimaryKey( array( 'id' ), 'pk_msordbase_id' );
191 191
 			$table->addUniqueIndex( array( 'siteid', 'baseid', 'code', 'type' ), 'unq_msordbase_sid_bid_cd_typ' );
@@ -198,7 +198,7 @@  discard block
 block discarded – undo
198 198
 			return $schema;
199 199
 		},
200 200
 
201
-		'mshop_order_base_service_attr' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
201
+		'mshop_order_base_service_attr' => function( \Doctrine\DBAL\Schema\Schema $schema ) {
202 202
 
203 203
 			$table = $schema->createTable( 'mshop_order_base_service_attr' );
204 204
 
@@ -213,7 +213,7 @@  discard block
 block discarded – undo
213 213
 			$table->addColumn( 'quantity', 'integer', [] );
214 214
 			$table->addColumn( 'mtime', 'datetime', [] );
215 215
 			$table->addColumn( 'ctime', 'datetime', [] );
216
-			$table->addColumn( 'editor', 'string', array('length' => 255 ) );
216
+			$table->addColumn( 'editor', 'string', array( 'length' => 255 ) );
217 217
 
218 218
 			$table->setPrimaryKey( array( 'id' ), 'pk_msordbaseat_id' );
219 219
 			$table->addUniqueIndex( array( 'ordservid', 'attrid', 'type', 'code' ), 'unq_msordbaseat_oid_aid_ty_cd' );
@@ -225,7 +225,7 @@  discard block
 block discarded – undo
225 225
 			return $schema;
226 226
 		},
227 227
 
228
-		'mshop_order_base_coupon' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
228
+		'mshop_order_base_coupon' => function( \Doctrine\DBAL\Schema\Schema $schema ) {
229 229
 
230 230
 			$table = $schema->createTable( 'mshop_order_base_coupon' );
231 231
 
@@ -236,7 +236,7 @@  discard block
 block discarded – undo
236 236
 			$table->addColumn( 'code', 'string', array( 'length' => 32 ) );
237 237
 			$table->addColumn( 'mtime', 'datetime', [] );
238 238
 			$table->addColumn( 'ctime', 'datetime', [] );
239
-			$table->addColumn( 'editor', 'string', array('length' => 255 ) );
239
+			$table->addColumn( 'editor', 'string', array( 'length' => 255 ) );
240 240
 
241 241
 			$table->setPrimaryKey( array( 'id' ), 'pk_msordbaco_id' );
242 242
 			$table->addIndex( array( 'siteid', 'baseid', 'code' ), 'idx_msordbaco_sid_bid_code' );
@@ -252,7 +252,7 @@  discard block
 block discarded – undo
252 252
 			return $schema;
253 253
 		},
254 254
 
255
-		'mshop_order' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
255
+		'mshop_order' => function( \Doctrine\DBAL\Schema\Schema $schema ) {
256 256
 
257 257
 			$table = $schema->createTable( 'mshop_order' );
258 258
 
@@ -272,7 +272,7 @@  discard block
 block discarded – undo
272 272
 			$table->addColumn( 'chour', 'string', array( 'length' => 2, 'fixed' => true ) );
273 273
 			$table->addColumn( 'ctime', 'datetime', [] );
274 274
 			$table->addColumn( 'mtime', 'datetime', [] );
275
-			$table->addColumn( 'editor', 'string', array('length' => 255 ) );
275
+			$table->addColumn( 'editor', 'string', array( 'length' => 255 ) );
276 276
 
277 277
 			$table->setPrimaryKey( array( 'id' ), 'pk_msord_id' );
278 278
 			$table->addIndex( array( 'siteid', 'type' ), 'idx_msord_sid_type' );
@@ -296,7 +296,7 @@  discard block
 block discarded – undo
296 296
 			return $schema;
297 297
 		},
298 298
 
299
-		'mshop_order_status' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
299
+		'mshop_order_status' => function( \Doctrine\DBAL\Schema\Schema $schema ) {
300 300
 
301 301
 			$table = $schema->createTable( 'mshop_order_status' );
302 302
 
@@ -307,7 +307,7 @@  discard block
 block discarded – undo
307 307
 			$table->addColumn( 'value', 'string', array( 'length' => 32 ) );
308 308
 			$table->addColumn( 'mtime', 'datetime', [] );
309 309
 			$table->addColumn( 'ctime', 'datetime', [] );
310
-			$table->addColumn( 'editor', 'string', array('length' => 255 ) );
310
+			$table->addColumn( 'editor', 'string', array( 'length' => 255 ) );
311 311
 
312 312
 			$table->setPrimaryKey( array( 'id' ), 'pk_msordst_id' );
313 313
 			$table->addIndex( array( 'siteid', 'parentid', 'type', 'value' ), 'idx_msordstatus_val_sid' );
Please login to merge, or discard this patch.
controller/common/tests/Controller/Common/Order/StandardTest.php 1 patch
Braces   +4 added lines, -2 removed lines patch added patch discarded remove patch
@@ -526,7 +526,8 @@  discard block
 block discarded – undo
526 526
 			->setMethods( array( 'saveItem' ) )
527 527
 			->getMock();
528 528
 
529
-		$stockStub->expects( $this->once() )->method( 'saveItem' )->with( $this->callback( function( $item ) {
529
+		$stockStub->expects( $this->once() )->method( 'saveItem' )->with( $this->callback( function( $item )
530
+		{
530 531
 			return $item->getStocklevel() === 10;
531 532
 		} ) );
532 533
 
@@ -579,7 +580,8 @@  discard block
 block discarded – undo
579 580
 			->setMethods( array( 'saveItem' ) )
580 581
 			->getMock();
581 582
 
582
-		$stockStub->expects( $this->once() )->method( 'saveItem' )->with( $this->callback( function( $item ) {
583
+		$stockStub->expects( $this->once() )->method( 'saveItem' )->with( $this->callback( function( $item )
584
+		{
583 585
 			return $item->getStocklevel() === 300;
584 586
 		} ) );
585 587
 
Please login to merge, or discard this patch.
lib/mshoplib/setup/default/schema/stock.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -8,7 +8,7 @@  discard block
 block discarded – undo
8 8
 
9 9
 return array(
10 10
 	'table' => array(
11
-		'mshop_stock_type' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
11
+		'mshop_stock_type' => function( \Doctrine\DBAL\Schema\Schema $schema ) {
12 12
 
13 13
 			$table = $schema->createTable( 'mshop_stock_type' );
14 14
 
@@ -31,7 +31,7 @@  discard block
 block discarded – undo
31 31
 			return $schema;
32 32
 		},
33 33
 
34
-		'mshop_stock' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
34
+		'mshop_stock' => function( \Doctrine\DBAL\Schema\Schema $schema ) {
35 35
 
36 36
 			$table = $schema->createTable( 'mshop_stock' );
37 37
 
Please login to merge, or discard this patch.
Braces   +4 added lines, -2 removed lines patch added patch discarded remove patch
@@ -8,7 +8,8 @@  discard block
 block discarded – undo
8 8
 
9 9
 return array(
10 10
 	'table' => array(
11
-		'mshop_stock_type' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
11
+		'mshop_stock_type' => function ( \Doctrine\DBAL\Schema\Schema $schema )
12
+		{
12 13
 
13 14
 			$table = $schema->createTable( 'mshop_stock_type' );
14 15
 
@@ -31,7 +32,8 @@  discard block
 block discarded – undo
31 32
 			return $schema;
32 33
 		},
33 34
 
34
-		'mshop_stock' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
35
+		'mshop_stock' => function ( \Doctrine\DBAL\Schema\Schema $schema )
36
+		{
35 37
 
36 38
 			$table = $schema->createTable( 'mshop_stock' );
37 39
 
Please login to merge, or discard this patch.
lib/mshoplib/setup/default/schema/product.php 2 patches
Braces   +12 added lines, -6 removed lines patch added patch discarded remove patch
@@ -8,7 +8,8 @@  discard block
 block discarded – undo
8 8
 
9 9
 return array(
10 10
 	'table' => array(
11
-		'mshop_product_type' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
11
+		'mshop_product_type' => function ( \Doctrine\DBAL\Schema\Schema $schema )
12
+		{
12 13
 
13 14
 			$table = $schema->createTable( 'mshop_product_type' );
14 15
 
@@ -31,7 +32,8 @@  discard block
 block discarded – undo
31 32
 			return $schema;
32 33
 		},
33 34
 
34
-		'mshop_product' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
35
+		'mshop_product' => function ( \Doctrine\DBAL\Schema\Schema $schema )
36
+		{
35 37
 
36 38
 			$table = $schema->createTable( 'mshop_product' );
37 39
 
@@ -63,7 +65,8 @@  discard block
 block discarded – undo
63 65
 			return $schema;
64 66
 		},
65 67
 
66
-		'mshop_product_list_type' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
68
+		'mshop_product_list_type' => function ( \Doctrine\DBAL\Schema\Schema $schema )
69
+		{
67 70
 
68 71
 			$table = $schema->createTable( 'mshop_product_list_type' );
69 72
 
@@ -86,7 +89,8 @@  discard block
 block discarded – undo
86 89
 			return $schema;
87 90
 		},
88 91
 
89
-		'mshop_product_list' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
92
+		'mshop_product_list' => function ( \Doctrine\DBAL\Schema\Schema $schema )
93
+		{
90 94
 
91 95
 			$table = $schema->createTable( 'mshop_product_list' );
92 96
 
@@ -124,7 +128,8 @@  discard block
 block discarded – undo
124 128
 			return $schema;
125 129
 		},
126 130
 
127
-		'mshop_product_property_type' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
131
+		'mshop_product_property_type' => function ( \Doctrine\DBAL\Schema\Schema $schema )
132
+		{
128 133
 
129 134
 			$table = $schema->createTable( 'mshop_product_property_type' );
130 135
 
@@ -147,7 +152,8 @@  discard block
 block discarded – undo
147 152
 			return $schema;
148 153
 		},
149 154
 
150
-		'mshop_product_property' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
155
+		'mshop_product_property' => function ( \Doctrine\DBAL\Schema\Schema $schema )
156
+		{
151 157
 
152 158
 			$table = $schema->createTable( 'mshop_product_property' );
153 159
 
Please login to merge, or discard this patch.
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -8,7 +8,7 @@  discard block
 block discarded – undo
8 8
 
9 9
 return array(
10 10
 	'table' => array(
11
-		'mshop_product_type' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
11
+		'mshop_product_type' => function( \Doctrine\DBAL\Schema\Schema $schema ) {
12 12
 
13 13
 			$table = $schema->createTable( 'mshop_product_type' );
14 14
 
@@ -31,7 +31,7 @@  discard block
 block discarded – undo
31 31
 			return $schema;
32 32
 		},
33 33
 
34
-		'mshop_product' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
34
+		'mshop_product' => function( \Doctrine\DBAL\Schema\Schema $schema ) {
35 35
 
36 36
 			$table = $schema->createTable( 'mshop_product' );
37 37
 
@@ -46,8 +46,8 @@  discard block
 block discarded – undo
46 46
 			$table->addColumn( 'status', 'smallint', [] );
47 47
 			$table->addColumn( 'mtime', 'datetime', [] );
48 48
 			$table->addColumn( 'ctime', 'datetime', [] );
49
-			$table->addColumn( 'editor', 'string', array('length' => 255 ) );
50
-			$table->addColumn( 'target', 'string', array('length' => 255 ) );
49
+			$table->addColumn( 'editor', 'string', array( 'length' => 255 ) );
50
+			$table->addColumn( 'target', 'string', array( 'length' => 255 ) );
51 51
 
52 52
 			$table->setPrimaryKey( array( 'id' ), 'pk_mspro_id' );
53 53
 			$table->addUniqueIndex( array( 'siteid', 'code' ), 'unq_mspro_siteid_code' );
@@ -64,7 +64,7 @@  discard block
 block discarded – undo
64 64
 			return $schema;
65 65
 		},
66 66
 
67
-		'mshop_product_list_type' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
67
+		'mshop_product_list_type' => function( \Doctrine\DBAL\Schema\Schema $schema ) {
68 68
 
69 69
 			$table = $schema->createTable( 'mshop_product_list_type' );
70 70
 
@@ -87,7 +87,7 @@  discard block
 block discarded – undo
87 87
 			return $schema;
88 88
 		},
89 89
 
90
-		'mshop_product_list' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
90
+		'mshop_product_list' => function( \Doctrine\DBAL\Schema\Schema $schema ) {
91 91
 
92 92
 			$table = $schema->createTable( 'mshop_product_list' );
93 93
 
@@ -125,7 +125,7 @@  discard block
 block discarded – undo
125 125
 			return $schema;
126 126
 		},
127 127
 
128
-		'mshop_product_property_type' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
128
+		'mshop_product_property_type' => function( \Doctrine\DBAL\Schema\Schema $schema ) {
129 129
 
130 130
 			$table = $schema->createTable( 'mshop_product_property_type' );
131 131
 
@@ -148,7 +148,7 @@  discard block
 block discarded – undo
148 148
 			return $schema;
149 149
 		},
150 150
 
151
-		'mshop_product_property' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
151
+		'mshop_product_property' => function( \Doctrine\DBAL\Schema\Schema $schema ) {
152 152
 
153 153
 			$table = $schema->createTable( 'mshop_product_property' );
154 154
 
Please login to merge, or discard this patch.
lib/mshoplib/src/MShop/Stock/Manager/Standard.php 2 patches
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -552,8 +552,8 @@  discard block
 block discarded – undo
552 552
 
553 553
 			while( ( $row = $results->fetch() ) !== false )
554 554
 			{
555
-				$map[ $row['stock.id'] ] = $row;
556
-				$typeIds[ $row['stock.typeid'] ] = null;
555
+				$map[$row['stock.id']] = $row;
556
+				$typeIds[$row['stock.typeid']] = null;
557 557
 			}
558 558
 
559 559
 			$dbm->release( $conn, $dbname );
@@ -576,9 +576,9 @@  discard block
 block discarded – undo
576 576
 
577 577
 			foreach( $map as $id => $row )
578 578
 			{
579
-				if( isset( $typeItems[ $row['stock.typeid'] ] ) )
579
+				if( isset( $typeItems[$row['stock.typeid']] ) )
580 580
 				{
581
-					$row['stock.type'] = $typeItems[ $row['stock.typeid'] ]->getCode();
581
+					$row['stock.type'] = $typeItems[$row['stock.typeid']]->getCode();
582 582
 					$row['stock.typename'] = $typeItems[$row['stock.typeid']]->getName();
583 583
 				}
584 584
 
Please login to merge, or discard this patch.
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -200,8 +200,7 @@
 block discarded – undo
200 200
 				 * @see mshop/stock/manager/standard/stocklevel
201 201
 				 */
202 202
 				$path = 'mshop/stock/manager/standard/insert';
203
-			}
204
-			else
203
+			} else
205 204
 			{
206 205
 				/** mshop/stock/manager/standard/update/mysql
207 206
 				 * Updates an existing product stock record in the database
Please login to merge, or discard this patch.