Completed
Push — master ( 52c730...9eba1c )
by Aimeos
08:52
created
lib/mshoplib/setup/MShopAddAttributeData.php 2 patches
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -51,7 +51,7 @@  discard block
 block discarded – undo
51 51
 		$this->msg( sprintf( 'Adding default attribute data for site "%1$s"', $site ), 0 );
52 52
 
53 53
 		$ds = DIRECTORY_SEPARATOR;
54
-		$path = __DIR__ . $ds . 'default' . $ds . 'data' . $ds . 'attribute.php';
54
+		$path = __DIR__.$ds.'default'.$ds.'data'.$ds.'attribute.php';
55 55
 
56 56
 		if( ( $data = include( $path ) ) == false ) {
57 57
 			throw new \Aimeos\MShop\Exception( sprintf( 'No file "%1$s" found for default codes', $path ) );
@@ -72,9 +72,9 @@  discard block
 block discarded – undo
72 72
 				$manager->saveItem( $item );
73 73
 				$num++;
74 74
 			}
75
-			catch( \Exception $e ) { ; } // if attribute was already available
75
+			catch( \Exception $e ) {; } // if attribute was already available
76 76
 		}
77 77
 
78
-		$this->status( $num > 0 ? $num . '/' . $total : 'OK' );
78
+		$this->status( $num > 0 ? $num.'/'.$total : 'OK' );
79 79
 	}
80 80
 }
81 81
\ No newline at end of file
Please login to merge, or discard this patch.
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -72,7 +72,9 @@
 block discarded – undo
72 72
 				$manager->saveItem( $item );
73 73
 				$num++;
74 74
 			}
75
-			catch( \Exception $e ) { ; } // if attribute was already available
75
+			catch( \Exception $e )
76
+			{
77
+; } // if attribute was already available
76 78
 		}
77 79
 
78 80
 		$this->status( $num > 0 ? $num . '/' . $total : 'OK' );
Please login to merge, or discard this patch.
lib/mshoplib/setup/MShopAddDataAbstract.php 2 patches
Spacing   +24 added lines, -24 removed lines patch added patch discarded remove patch
@@ -79,7 +79,7 @@  discard block
 block discarded – undo
79 79
 	{
80 80
 		$context = $this->getContext();
81 81
 		$attrManager = \Aimeos\MShop\Factory::createManager( $context, 'attribute' );
82
-		$listManager = \Aimeos\MShop\Factory::createManager( $context, $domain . '/lists' );
82
+		$listManager = \Aimeos\MShop\Factory::createManager( $context, $domain.'/lists' );
83 83
 
84 84
 
85 85
 		$item = $attrManager->createItem();
@@ -110,7 +110,7 @@  discard block
 block discarded – undo
110 110
 			}
111 111
 
112 112
 			$listItem->setId( null );
113
-			$listItem->setTypeId( $this->getTypeId( $domain . '/lists/type', 'attribute', $entry['list-type'] ) );
113
+			$listItem->setTypeId( $this->getTypeId( $domain.'/lists/type', 'attribute', $entry['list-type'] ) );
114 114
 			$listItem->setDateStart( $entry['list-start'] );
115 115
 			$listItem->setDateEnd( $entry['list-end'] );
116 116
 			$listItem->setConfig( $entry['list-config'] );
@@ -151,7 +151,7 @@  discard block
 block discarded – undo
151 151
 	{
152 152
 		$context = $this->getContext();
153 153
 		$mediaManager = \Aimeos\MShop\Factory::createManager( $context, 'media' );
154
-		$listManager = \Aimeos\MShop\Factory::createManager( $context, $domain . '/lists' );
154
+		$listManager = \Aimeos\MShop\Factory::createManager( $context, $domain.'/lists' );
155 155
 
156 156
 
157 157
 		$item = $mediaManager->createItem();
@@ -176,7 +176,7 @@  discard block
 block discarded – undo
176 176
 			$mediaManager->saveItem( $item );
177 177
 
178 178
 			$listItem->setId( null );
179
-			$listItem->setTypeId( $this->getTypeId( $domain . '/lists/type', 'media', $entry['list-type'] ) );
179
+			$listItem->setTypeId( $this->getTypeId( $domain.'/lists/type', 'media', $entry['list-type'] ) );
180 180
 			$listItem->setDateStart( $entry['list-start'] );
181 181
 			$listItem->setDateEnd( $entry['list-end'] );
182 182
 			$listItem->setConfig( $entry['list-config'] );
@@ -217,7 +217,7 @@  discard block
 block discarded – undo
217 217
 	{
218 218
 		$context = $this->getContext();
219 219
 		$mediaManager = \Aimeos\MShop\Factory::createManager( $context, 'price' );
220
-		$listManager = \Aimeos\MShop\Factory::createManager( $context, $domain . '/lists' );
220
+		$listManager = \Aimeos\MShop\Factory::createManager( $context, $domain.'/lists' );
221 221
 
222 222
 
223 223
 		$item = $mediaManager->createItem();
@@ -244,7 +244,7 @@  discard block
 block discarded – undo
244 244
 			$mediaManager->saveItem( $item );
245 245
 
246 246
 			$listItem->setId( null );
247
-			$listItem->setTypeId( $this->getTypeId( $domain . '/lists/type', 'price', $entry['list-type'] ) );
247
+			$listItem->setTypeId( $this->getTypeId( $domain.'/lists/type', 'price', $entry['list-type'] ) );
248 248
 			$listItem->setDateStart( $entry['list-start'] );
249 249
 			$listItem->setDateEnd( $entry['list-end'] );
250 250
 			$listItem->setConfig( $entry['list-config'] );
@@ -285,7 +285,7 @@  discard block
 block discarded – undo
285 285
 	{
286 286
 		$context = $this->getContext();
287 287
 		$textManager = \Aimeos\MShop\Factory::createManager( $context, 'text' );
288
-		$listManager = \Aimeos\MShop\Factory::createManager( $context, $domain . '/lists' );
288
+		$listManager = \Aimeos\MShop\Factory::createManager( $context, $domain.'/lists' );
289 289
 
290 290
 
291 291
 		$item = $textManager->createItem();
@@ -308,7 +308,7 @@  discard block
 block discarded – undo
308 308
 			$textManager->saveItem( $item );
309 309
 
310 310
 			$listItem->setId( null );
311
-			$listItem->setTypeId( $this->getTypeId( $domain . '/lists/type', 'text', $entry['list-type'] ) );
311
+			$listItem->setTypeId( $this->getTypeId( $domain.'/lists/type', 'text', $entry['list-type'] ) );
312 312
 			$listItem->setDateStart( $entry['list-start'] );
313 313
 			$listItem->setDateEnd( $entry['list-end'] );
314 314
 			$listItem->setConfig( $entry['list-config'] );
@@ -349,7 +349,7 @@  discard block
 block discarded – undo
349 349
 	{
350 350
 		$context = $this->getContext();
351 351
 		$productManager = \Aimeos\MShop\Factory::createManager( $context, 'product' );
352
-		$listManager = \Aimeos\MShop\Factory::createManager( $context, $domain . '/lists' );
352
+		$listManager = \Aimeos\MShop\Factory::createManager( $context, $domain.'/lists' );
353 353
 
354 354
 
355 355
 		$listItem = $listManager->createItem();
@@ -379,7 +379,7 @@  discard block
 block discarded – undo
379 379
 			}
380 380
 
381 381
 			$listItem->setId( null );
382
-			$listItem->setTypeId( $this->getTypeId( $domain . '/lists/type', 'product', $entry['list-type'] ) );
382
+			$listItem->setTypeId( $this->getTypeId( $domain.'/lists/type', 'product', $entry['list-type'] ) );
383 383
 			$listItem->setDateStart( $entry['list-start'] );
384 384
 			$listItem->setDateEnd( $entry['list-end'] );
385 385
 			$listItem->setConfig( $entry['list-config'] );
@@ -475,8 +475,8 @@  discard block
 block discarded – undo
475 475
 
476 476
 		$search = $manager->createSearch();
477 477
 		$expr = array(
478
-			$search->compare( '==', $key . '.domain', $domain ),
479
-			$search->compare( '==', $key . '.code', $type ),
478
+			$search->compare( '==', $key.'.domain', $domain ),
479
+			$search->compare( '==', $key.'.code', $type ),
480 480
 		);
481 481
 		$search->setConditions( $search->combine( '&&', $expr ) );
482 482
 
@@ -509,8 +509,8 @@  discard block
 block discarded – undo
509 509
 
510 510
 		$search = $manager->createSearch();
511 511
 		$expr = array(
512
-			$search->compare( '==', $refdomain . '.domain', $domain ),
513
-			$search->compare( '=~', $refdomain . '.label', 'Demo' ),
512
+			$search->compare( '==', $refdomain.'.domain', $domain ),
513
+			$search->compare( '=~', $refdomain.'.label', 'Demo' ),
514 514
 		);
515 515
 		$search->setConditions( $search->combine( '&&', $expr ) );
516 516
 
@@ -520,9 +520,9 @@  discard block
 block discarded – undo
520 520
 
521 521
 		$search = $listManager->createSearch();
522 522
 		$expr = array(
523
-			$search->compare( '==', $key . '.parentid', $parentid ),
524
-			$search->compare( '==', $key . '.domain', $refdomain ),
525
-			$search->compare( '==', $key . '.refid', $ids ),
523
+			$search->compare( '==', $key.'.parentid', $parentid ),
524
+			$search->compare( '==', $key.'.domain', $refdomain ),
525
+			$search->compare( '==', $key.'.refid', $ids ),
526 526
 		);
527 527
 		$search->setConditions( $search->combine( '&&', $expr ) );
528 528
 
@@ -550,8 +550,8 @@  discard block
 block discarded – undo
550 550
 
551 551
 		$search = $listManager->createSearch();
552 552
 		$expr = array(
553
-			$search->compare( '==', $key . '.parentid', $parentid ),
554
-			$search->compare( '==', $key . '.domain', $refdomain ),
553
+			$search->compare( '==', $key.'.parentid', $parentid ),
554
+			$search->compare( '==', $key.'.domain', $refdomain ),
555 555
 		);
556 556
 		$search->setConditions( $search->combine( '&&', $expr ) );
557 557
 
@@ -568,7 +568,7 @@  discard block
 block discarded – undo
568 568
 
569 569
 
570 570
 			$search = $manager->createSearch();
571
-			$search->setConditions( $search->compare( '==', $refdomain . '.id', $refIds ) );
571
+			$search->setConditions( $search->compare( '==', $refdomain.'.id', $refIds ) );
572 572
 			$ids = array_keys( $manager->searchItems( $search ) );
573 573
 
574 574
 			foreach( array_diff( $refIds, $ids ) as $refId ) {
@@ -586,14 +586,14 @@  discard block
 block discarded – undo
586 586
 
587 587
 
588 588
 		$search = $manager->createSearch();
589
-		$search->setConditions( $search->compare( '=~', $refdomain . '.label', 'Demo' ) );
589
+		$search->setConditions( $search->compare( '=~', $refdomain.'.label', 'Demo' ) );
590 590
 		$ids = array_keys( $manager->searchItems( $search ) );
591 591
 
592 592
 		$search = $listManager->createSearch();
593 593
 		$expr = array(
594
-			$search->compare( '==', $key . '.parentid', $parentid ),
595
-			$search->compare( '==', $key . '.refid', $ids ),
596
-			$search->compare( '==', $key . '.domain', $refdomain ),
594
+			$search->compare( '==', $key.'.parentid', $parentid ),
595
+			$search->compare( '==', $key.'.refid', $ids ),
596
+			$search->compare( '==', $key.'.domain', $refdomain ),
597 597
 		);
598 598
 		$search->setConditions( $search->combine( '&&', $expr ) );
599 599
 
Please login to merge, or discard this patch.
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -103,8 +103,7 @@
 block discarded – undo
103 103
 
104 104
 				$attrManager->saveItem( $item );
105 105
 				$id = $item->getId();
106
-			}
107
-			else
106
+			} else
108 107
 			{
109 108
 				$id = $attrItem->getId();
110 109
 			}
Please login to merge, or discard this patch.
lib/mshoplib/src/MShop/Common/Manager/Address/Base.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -60,7 +60,7 @@  discard block
 block discarded – undo
60 60
 	 */
61 61
 	public function createItem()
62 62
 	{
63
-		$values = array( $this->prefix . 'siteid' => $this->getContext()->getLocale()->getSiteId() );
63
+		$values = array( $this->prefix.'siteid' => $this->getContext()->getLocale()->getSiteId() );
64 64
 		return $this->createItemBase( $values );
65 65
 	}
66 66
 
@@ -72,7 +72,7 @@  discard block
 block discarded – undo
72 72
 	 */
73 73
 	public function deleteItems( array $ids )
74 74
 	{
75
-		$this->deleteItemsBase( $ids, $this->getConfigPath() . 'delete' );
75
+		$this->deleteItemsBase( $ids, $this->getConfigPath().'delete' );
76 76
 	}
77 77
 
78 78
 
@@ -125,7 +125,7 @@  discard block
 block discarded – undo
125 125
 				$type = 'update';
126 126
 			}
127 127
 
128
-			$stmt = $this->getCachedStatement( $conn, $this->getConfigPath() . $type );
128
+			$stmt = $this->getCachedStatement( $conn, $this->getConfigPath().$type );
129 129
 
130 130
 			$stmt->bind( 1, $item->getParentId(), \Aimeos\MW\DB\Statement\Base::PARAM_INT );
131 131
 			$stmt->bind( 2, $item->getCompany() );
@@ -135,7 +135,7 @@  discard block
 block discarded – undo
135 135
 			$stmt->bind( 6, $item->getFirstname() );
136 136
 			$stmt->bind( 7, $item->getLastname() );
137 137
 			$stmt->bind( 8, $item->getAddress1() );
138
-			$stmt->bind( 9, $item->getAddress2());
138
+			$stmt->bind( 9, $item->getAddress2() );
139 139
 			$stmt->bind( 10, $item->getAddress3() );
140 140
 			$stmt->bind( 11, $item->getPostal() );
141 141
 			$stmt->bind( 12, $item->getCity() );
@@ -165,7 +165,7 @@  discard block
 block discarded – undo
165 165
 
166 166
 			if( $id === null && $fetch === true )
167 167
 			{
168
-				$path = $this->getConfigPath() . 'newid';
168
+				$path = $this->getConfigPath().'newid';
169 169
 				$item->setId( $this->newId( $conn, $path ) );
170 170
 			}
171 171
 
@@ -204,13 +204,13 @@  discard block
 block discarded – undo
204 204
 
205 205
 			$required = array( trim( $this->prefix, '.' ) );
206 206
 			$level = \Aimeos\MShop\Locale\Manager\Base::SITE_ALL;
207
-			$cfgPathSearch = $this->getConfigPath() . 'search';
208
-			$cfgPathCount = $this->getConfigPath() . 'count';
207
+			$cfgPathSearch = $this->getConfigPath().'search';
208
+			$cfgPathCount = $this->getConfigPath().'count';
209 209
 
210 210
 			$results = $this->searchItemsBase( $conn, $search, $cfgPathSearch, $cfgPathCount, $required, $total, $level );
211 211
 
212 212
 			while( ( $row = $results->fetch() ) !== false ) {
213
-				$items[$row[$this->prefix . 'id']] = $this->createItemBase( $row );
213
+				$items[$row[$this->prefix.'id']] = $this->createItemBase( $row );
214 214
 			}
215 215
 
216 216
 			$dbm->release( $conn, $dbname );
@@ -234,7 +234,7 @@  discard block
 block discarded – undo
234 234
 	 */
235 235
 	public function getSubManager( $manager, $name = null )
236 236
 	{
237
-		return $this->getSubManagerBase( 'common', 'address/' . $manager, $name );
237
+		return $this->getSubManagerBase( 'common', 'address/'.$manager, $name );
238 238
 	}
239 239
 
240 240
 
Please login to merge, or discard this patch.
lib/mwlib/src/MW/Logger/File.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -60,7 +60,7 @@
 block discarded – undo
60 60
 				$message = json_encode( $message );
61 61
 			}
62 62
 
63
-			$message = '<' . $facility . '> ' . date( 'Y-m-d H:i:s' ) . ' ' . $priority . ' ' . $message . PHP_EOL;
63
+			$message = '<'.$facility.'> '.date( 'Y-m-d H:i:s' ).' '.$priority.' '.$message.PHP_EOL;
64 64
 
65 65
 			if( file_put_contents( $this->filename, $message, FILE_APPEND ) === false ) {
66 66
 				throw new \Aimeos\MW\Logger\Exception( sprintf( 'Unable to write to file "%1$s', $this->filename ) );
Please login to merge, or discard this patch.
lib/mwlib/src/MW/DB/Statement/PDO/Simple.php 1 patch
Braces   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -92,9 +92,12 @@
 block discarded – undo
92 92
 		}
93 93
 		catch( \PDOException $e )
94 94
 		{
95
-			try {
95
+			try
96
+			{
96 97
 				$result = $this->reconnect( $e )->exec();
97
-			} catch( \PDOException $e ) {
98
+			}
99
+			catch( \PDOException $e )
100
+			{
98 101
 				throw new \Aimeos\MW\DB\Exception( $e->getMessage(), $e->getCode() );
99 102
 			}
100 103
 		}
Please login to merge, or discard this patch.
lib/mwlib/src/MW/DB/Statement/PDO/Prepared.php 1 patch
Braces   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -65,9 +65,12 @@
 block discarded – undo
65 65
 		}
66 66
 		catch( \PDOException $e )
67 67
 		{
68
-			try {
68
+			try
69
+			{
69 70
 				$stmt = $this->reconnect( $e )->exec();
70
-			} catch( \PDOException $e ) {
71
+			}
72
+			catch( \PDOException $e )
73
+			{
71 74
 				throw new \Aimeos\MW\DB\Exception( $e->getMessage(), $e->getCode(), $e->errorInfo );
72 75
 			}
73 76
 		}
Please login to merge, or discard this patch.
lib/mwlib/src/MW/DB/Statement/DBAL/Simple.php 1 patch
Braces   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -91,9 +91,12 @@
 block discarded – undo
91 91
 		}
92 92
 		catch( \Doctrine\DBAL\DBALException $e )
93 93
 		{
94
-			try {
94
+			try
95
+			{
95 96
 				$result = $this->reconnect( $e )->exec();
96
-			} catch( \Doctrine\DBAL\DBALException $e ) {
97
+			}
98
+			catch( \Doctrine\DBAL\DBALException $e )
99
+			{
97 100
 				throw new \Aimeos\MW\DB\Exception( $e->getMessage(), $e->getCode() );
98 101
 			}
99 102
 		}
Please login to merge, or discard this patch.
lib/mwlib/src/MW/DB/Statement/DBAL/Prepared.php 1 patch
Braces   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -64,9 +64,12 @@
 block discarded – undo
64 64
 		}
65 65
 		catch( \Doctrine\DBAL\DBALException $e )
66 66
 		{
67
-			try {
67
+			try
68
+			{
68 69
 				$stmt = $this->reconnect( $e )->exec();
69
-			} catch( \Doctrine\DBAL\DBALException $e ) {
70
+			}
71
+			catch( \Doctrine\DBAL\DBALException $e )
72
+			{
70 73
 				throw new \Aimeos\MW\DB\Exception( $e->getMessage(), $e->getCode() );
71 74
 			}
72 75
 		}
Please login to merge, or discard this patch.
lib/mshoplib/setup/MShopAddLocaleData.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -174,7 +174,7 @@  discard block
 block discarded – undo
174 174
 			$num++;
175 175
 		}
176 176
 
177
-		$this->status( $num > 0 ? $num . '/' . $total : 'OK' );
177
+		$this->status( $num > 0 ? $num.'/'.$total : 'OK' );
178 178
 	}
179 179
 
180 180
 
@@ -211,7 +211,7 @@  discard block
 block discarded – undo
211 211
 			$num++;
212 212
 		}
213 213
 
214
-		$this->status( $num > 0 ? $num . '/' . $total : 'OK' );
214
+		$this->status( $num > 0 ? $num.'/'.$total : 'OK' );
215 215
 	}
216 216
 
217 217
 
Please login to merge, or discard this patch.
Braces   +6 added lines, -2 removed lines patch added patch discarded remove patch
@@ -240,9 +240,13 @@
 block discarded – undo
240 240
 			$localeItem->setPosition( $dataset['pos'] );
241 241
 			$localeItem->setStatus( $dataset['status'] );
242 242
 
243
-			try {
243
+			try
244
+			{
244 245
 				$localeItemManager->saveItem( $localeItem );
245
-			} catch( \Exception $e ) {; } // if locale combination was already available
246
+			}
247
+			catch( \Exception $e )
248
+			{
249
+; } // if locale combination was already available
246 250
 		}
247 251
 
248 252
 		$this->status( 'done' );
Please login to merge, or discard this patch.