Passed
Push — master ( c9773b...29143b )
by Aimeos
05:44
created
lib/mshoplib/src/MShop/Review/Manager/Standard.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -323,8 +323,7 @@
 block discarded – undo
323 323
 				 */
324 324
 				$path = 'mshop/review/manager/insert';
325 325
 				$sql = $this->addSqlColumns( array_keys( $columns ), $this->getSqlConfig( $path ) );
326
-			}
327
-			else
326
+			} else
328 327
 			{
329 328
 				/** mshop/review/manager/update/mysql
330 329
 				 * Updates an existing review record in the database
Please login to merge, or discard this patch.
lib/mshoplib/setup/unitperf/CatalogAddPerfData.php 1 patch
Braces   +6 added lines, -4 removed lines patch added patch discarded remove patch
@@ -79,8 +79,7 @@  discard block
 block discarded – undo
79 79
 				for( $i = 0; $i < $numCatPerLevel; $i++ ) {
80 80
 					$treeFcn( $parents, $catItem->getId(), $numCatPerLevel, $level - 1, $catLabel . '-' . ( $i + 1 ), $i );
81 81
 				}
82
-			}
83
-			else
82
+			} else
84 83
 			{
85 84
 				$fcn = function( array $parents, $catLabel ) {
86 85
 
@@ -139,9 +138,12 @@  discard block
 block discarded – undo
139 138
 
140 139
 		while( true )
141 140
 		{
142
-			try {
141
+			try
142
+			{
143 143
 				return $catalogManager->insert( $item, $parentId );
144
-			} catch( \Aimeos\MW\DB\Exception $e ) {
144
+			}
145
+			catch( \Aimeos\MW\DB\Exception $e )
146
+			{
145 147
 				if( $e->getCode() !== 40001 ) { throw $e; } // transaction deadlock
146 148
 			}
147 149
 		}
Please login to merge, or discard this patch.
lib/mshoplib/src/MShop/Catalog/Manager/Standard.php 1 patch
Braces   +13 added lines, -10 removed lines patch added patch discarded remove patch
@@ -721,9 +721,12 @@  discard block
 block discarded – undo
721 721
 
722 722
 		foreach( $sitePath as $siteId )
723 723
 		{
724
-			try {
724
+			try
725
+			{
725 726
 				$path = $this->createTreeManager( $siteId )->getPath( $id );
726
-			} catch( \Exception $e ) {
727
+			}
728
+			catch( \Exception $e )
729
+			{
727 730
 				continue;
728 731
 			}
729 732
 
@@ -759,9 +762,12 @@  discard block
 block discarded – undo
759 762
 
760 763
 		foreach( $sitePath as $siteId )
761 764
 		{
762
-			try {
765
+			try
766
+			{
763 767
 				$node = $this->createTreeManager( $siteId )->getNode( $id, $level, $criteria );
764
-			} catch( \Aimeos\MW\Tree\Exception $e ) {
768
+			}
769
+			catch( \Aimeos\MW\Tree\Exception $e )
770
+			{
765 771
 				continue;
766 772
 			}
767 773
 
@@ -842,8 +848,7 @@  discard block
 block discarded – undo
842 848
 				if( $child->getParentId() !== $item->getParentId() ) {
843 849
 					$this->move( $child->getId(), $item->getParentId(), $child->getParentId() );
844 850
 				}
845
-			}
846
-			else
851
+			} else
847 852
 			{
848 853
 				$this->insert( $child, $item->getId() );
849 854
 			}
@@ -1002,8 +1007,7 @@  discard block
 block discarded – undo
1002 1007
 				 */
1003 1008
 				$path = 'mshop/catalog/manager/update-usage';
1004 1009
 				$sql = $this->addSqlColumns( array_keys( $columns ), $this->getSqlConfig( $path ), false );
1005
-			}
1006
-			else
1010
+			} else
1007 1011
 			{
1008 1012
 				/** mshop/catalog/manager/insert-usage/mysql
1009 1013
 				 * Updates the config, editor, ctime and mtime value of an inserted record
@@ -1067,8 +1071,7 @@  discard block
 block discarded – undo
1067 1071
 			{
1068 1072
 				$stmt->bind( $idx++, $siteid );
1069 1073
 				$stmt->bind( $idx++, $id, \Aimeos\MW\DB\Statement\Base::PARAM_INT );
1070
-			}
1071
-			else
1074
+			} else
1072 1075
 			{
1073 1076
 				$stmt->bind( $idx++, $date ); // ctime
1074 1077
 				$stmt->bind( $idx++, $siteid );
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
@@ -71,9 +71,12 @@
 block discarded – undo
71 71
 	 */
72 72
 	public function execute() : \Aimeos\MW\DB\Result\Iface
73 73
 	{
74
-		try {
74
+		try
75
+		{
75 76
 			$stmt = $this->exec();
76
-		} catch( \PDOException $e ) {
77
+		}
78
+		catch( \PDOException $e )
79
+		{
77 80
 			throw new \Aimeos\MW\DB\Exception( $e->getMessage() . ': ' . $this->sql . map( $this->binds )->col( 0 )->toJson(), $e->getCode() );
78 81
 		}
79 82
 
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
@@ -72,9 +72,12 @@
 block discarded – undo
72 72
 	 */
73 73
 	public function execute() : \Aimeos\MW\DB\Result\Iface
74 74
 	{
75
-		try {
75
+		try
76
+		{
76 77
 			$stmt = $this->exec();
77
-		} catch( \PDOException $e ) {
78
+		}
79
+		catch( \PDOException $e )
80
+		{
78 81
 			throw new \Aimeos\MW\DB\Exception( $e->getMessage() . ': ' . $this->sql . map( $this->binds )->col( 0 )->toJson(), $e->getCode(), $e->errorInfo );
79 82
 		}
80 83
 
Please login to merge, or discard this patch.
lib/mshoplib/src/MShop/Common/Manager/ListsRef/Traits.php 1 patch
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -178,8 +178,7 @@  discard block
 block discarded – undo
178 178
 						$search->compare( '==', $prefix . '.lists.domain', $key ),
179 179
 						$search->compare( '==', $prefix . '.lists.type', $domain ),
180 180
 					] );
181
-				}
182
-				else
181
+				} else
183 182
 				{
184 183
 					$list[] = $search->compare( '==', $prefix . '.lists.domain', $domain );
185 184
 				}
@@ -187,8 +186,7 @@  discard block
 block discarded – undo
187 186
 
188 187
 			$expr[] = $search->or( $list );
189 188
 			$search->setConditions( $search->and( $expr ) );
190
-		}
191
-		else
189
+		} else
192 190
 		{
193 191
 			$search->setConditions( $search->compare( '==', $prefix . '.lists.parentid', $ids ) );
194 192
 		}
Please login to merge, or discard this patch.
lib/mshoplib/src/MShop/Rule/Manager/Standard.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -378,8 +378,7 @@
 block discarded – undo
378 378
 				 */
379 379
 				$path = 'mshop/rule/manager/insert';
380 380
 				$sql = $this->addSqlColumns( array_keys( $columns ), $this->getSqlConfig( $path ) );
381
-			}
382
-			else
381
+			} else
383 382
 			{
384 383
 				/** mshop/rule/manager/update/mysql
385 384
 				 * Updates an existing rule record in the database
Please login to merge, or discard this patch.
lib/mwlib/src/MW/Process/Pcntl.php 1 patch
Braces   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -110,9 +110,12 @@
 block discarded – undo
110 110
 			throw new Exception( 'Unable to fork new process: ' . pcntl_strerror( pcntl_get_last_error() ) );
111 111
 		}
112 112
 
113
-		if( $pid === 0 ) // child process
113
+		if( $pid === 0 ) {
114
+			// child process
114 115
 		{
115
-			$this->list = []; // use own child process list
116
+			$this->list = [];
117
+		}
118
+		// use own child process list
116 119
 			exit( $this->exec( $fcn, $data ) );
117 120
 		}
118 121
 
Please login to merge, or discard this patch.
lib/mshoplib/setup/StockMigrateProductId.php 1 patch
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -82,8 +82,7 @@  discard block
 block discarded – undo
82 82
 			{
83 83
 				$this->executeList( $this->updates );
84 84
 				$this->status( 'done' );
85
-			}
86
-			else
85
+			} else
87 86
 			{
88 87
 				$this->status( 'OK' );
89 88
 			}
@@ -96,8 +95,7 @@  discard block
 block discarded – undo
96 95
 			{
97 96
 				$this->execute( $this->column );
98 97
 				$this->status( 'done' );
99
-			}
100
-			else
98
+			} else
101 99
 			{
102 100
 				$this->status( 'OK' );
103 101
 			}
Please login to merge, or discard this patch.