Passed
Push — master ( 47e37b...2360ce )
by Aimeos
05:11
created
lib/mshoplib/src/MShop/Plugin/Provider/Order/PropertyMatch.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -110,8 +110,7 @@
 block discarded – undo
110 110
 				\Aimeos\MW\Common\Base::checkClass( \Aimeos\MShop\Order\Item\Base\Product\Iface::class, $orderProduct );
111 111
 				$list[] = $orderProduct->getProductId();
112 112
 			}
113
-		}
114
-		else
113
+		} else
115 114
 		{
116 115
 			\Aimeos\MW\Common\Base::checkClass( \Aimeos\MShop\Order\Item\Base\Product\Iface::class, $value );
117 116
 			$list[] = $value->getProductId();
Please login to merge, or discard this patch.
lib/mshoplib/src/MShop/Index/Manager/Standard.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -190,7 +190,7 @@
 block discarded – undo
190 190
 	 * Removes old entries from the storage.
191 191
 	 *
192 192
 	 * @param string[] $siteids List of IDs for sites whose entries should be deleted
193
-	* @return \Aimeos\MShop\Index\Manager\Iface Manager object for chaining method calls
193
+	 * @return \Aimeos\MShop\Index\Manager\Iface Manager object for chaining method calls
194 194
 	 */
195 195
 	public function cleanup( array $siteids )
196 196
 	{
Please login to merge, or discard this patch.
lib/mshoplib/src/MShop/Common/Item/ListRef/Traits.php 1 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
 				$refItem = $item->getRefItem();
210 210
 
211
-				if( $type && ( !$refItem || !($refItem instanceof $iface) || !in_array( $refItem->getType(), $types ) ) ) {
211
+				if( $type && ( !$refItem || !( $refItem instanceof $iface ) || !in_array( $refItem->getType(), $types ) ) ) {
212 212
 					continue;
213 213
 				}
214 214
 
Please login to merge, or discard this patch.
controller/jobs/src/Controller/Jobs.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -124,8 +124,7 @@
 block discarded – undo
124 124
 				$subList = self::createControllers( $it, $context, $aimeos, $pref );
125 125
 
126 126
 				$list = array_merge( $list, $subList );
127
-			}
128
-			else if( $prefix !== '' && $entry->getType() === 'file'
127
+			} else if( $prefix !== '' && $entry->getType() === 'file'
129 128
 				&& $entry->getBaseName( '.php' ) === 'Factory' )
130 129
 			{
131 130
 				$list[$prefix] = self::create( $context, $aimeos, $prefix );
Please login to merge, or discard this patch.
lib/mshoplib/setup/default/DemoAddProductData.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -173,7 +173,7 @@
 block discarded – undo
173 173
 					$manager = \Aimeos\MShop::create( $context, 'attribute' );
174 174
 					$refItem = $manager->findItem( $refItem->getCode(), [], $domain, $refItem->getType() );
175 175
 				}
176
-				catch( \Aimeos\MShop\Exception $e ) { ; } // attribute doesn't exist yet
176
+				catch( \Aimeos\MShop\Exception $e ) {; } // attribute doesn't exist yet
177 177
 
178 178
 				$refItem = $this->addRefItems( $refItem, $data );
179 179
 				$item->addListItem( 'attribute', $listItem, $refItem );
Please login to merge, or discard this patch.
Braces   +4 added lines, -3 removed lines patch added patch discarded remove patch
@@ -81,8 +81,7 @@  discard block
 block discarded – undo
81 81
 		{
82 82
 			$this->addDemoData();
83 83
 			$this->status( 'added' );
84
-		}
85
-		else
84
+		} else
86 85
 		{
87 86
 			$this->status( 'removed' );
88 87
 		}
@@ -173,7 +172,9 @@  discard block
 block discarded – undo
173 172
 					$manager = \Aimeos\MShop::create( $context, 'attribute' );
174 173
 					$refItem = $manager->findItem( $refItem->getCode(), [], $domain, $refItem->getType() );
175 174
 				}
176
-				catch( \Aimeos\MShop\Exception $e ) { ; } // attribute doesn't exist yet
175
+				catch( \Aimeos\MShop\Exception $e )
176
+				{
177
+; } // attribute doesn't exist yet
177 178
 
178 179
 				$refItem = $this->addRefItems( $refItem, $data );
179 180
 				$item->addListItem( 'attribute', $listItem, $refItem );
Please login to merge, or discard this patch.
lib/mshoplib/src/MShop/Context/Item/Standard.php 1 patch
Indentation   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -434,7 +434,7 @@  discard block
 block discarded – undo
434 434
 	 * Returns the message queue manager object.
435 435
 	 *
436 436
 	 * @return \Aimeos\MW\MQueue\Manager\Iface Message queue manager object
437
-	*/
437
+	 */
438 438
 	public function getMessageQueueManager()
439 439
 	{
440 440
 		if( !isset( $this->mqueue ) ) {
@@ -451,7 +451,7 @@  discard block
 block discarded – undo
451 451
 	 * @param string $resource Resource name, e.g. "mq-email"
452 452
 	 * @param string $queue Message queue name, e.g. "order/email/payment"
453 453
 	 * @return \Aimeos\MW\MQueue\Manager\Iface Message queue object
454
-	*/
454
+	 */
455 455
 	public function getMessageQueue( $resource, $queue )
456 456
 	{
457 457
 		if( !isset( $this->mqueue ) ) {
@@ -480,7 +480,7 @@  discard block
 block discarded – undo
480 480
 	 * Returns the process object.
481 481
 	 *
482 482
 	 * @return \Aimeos\MW\Process\Iface Process object
483
-	*/
483
+	 */
484 484
 	public function getProcess()
485 485
 	{
486 486
 		if( !isset( $this->process ) ) {
Please login to merge, or discard this patch.
lib/mshoplib/src/MShop/Plugin/Provider/Order/ProductLimit.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -133,8 +133,7 @@
 block discarded – undo
133 133
 				$this->checkWithoutCurrency( $order, $entry );
134 134
 				$this->checkWithCurrency( $order, $entry );
135 135
 			}
136
-		}
137
-		else
136
+		} else
138 137
 		{
139 138
 			\Aimeos\MW\Common\Base::checkClass( \Aimeos\MShop\Order\Item\Base\Product\Iface::class, $value );
140 139
 
Please login to merge, or discard this patch.
lib/mwlib/src/MW/Tree/Node/Standard.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -154,7 +154,7 @@
 block discarded – undo
154 154
 			$this->modified = true;
155 155
 		}
156 156
 
157
-		return $this;;
157
+		return $this; ;
158 158
 	}
159 159
 
160 160
 
Please login to merge, or discard this patch.
lib/mshoplib/src/MShop/Service/Provider/Decorator/Weight.php 2 patches
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -96,9 +96,11 @@
 block discarded – undo
96 96
 			$code = $orderProduct->getProductCode();
97 97
 			$prodMap[$code] = ( isset( $prodMap[$code] ) ? $prodMap[$code] + $qty : $qty );
98 98
 
99
-			foreach( $orderProduct->getProducts() as $prodItem ) // calculate bundled products
99
+			foreach( $orderProduct->getProducts() as $prodItem ) {
100
+				// calculate bundled products
100 101
 			{
101 102
 				$qty = $prodItem->getQuantity();
103
+			}
102 104
 				$code = $prodItem->getProductCode();
103 105
 				$prodMap[$code] = ( isset( $prodMap[$code] ) ? $prodMap[$code] + $qty : $qty );
104 106
 			}
Please login to merge, or discard this patch.
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -104,7 +104,7 @@  discard block
 block discarded – undo
104 104
 			}
105 105
 		}
106 106
 
107
-		if ( $this->checkWeightScale( $this->getWeight( $prodMap ) ) === false ) {
107
+		if( $this->checkWeightScale( $this->getWeight( $prodMap ) ) === false ) {
108 108
 			return false;
109 109
 		}
110 110
 
@@ -123,11 +123,11 @@  discard block
 block discarded – undo
123 123
 		$min = $this->getConfigValue( array( 'weight.min' ) );
124 124
 		$max = $this->getConfigValue( array( 'weight.max' ) );
125 125
 
126
-		if( $min !== null && ( (float) $min) > $basketWeight ) {
126
+		if( $min !== null && ( (float) $min ) > $basketWeight ) {
127 127
 			return false;
128 128
 		}
129 129
 
130
-		if( $max !== null && ( (float) $max) < $basketWeight ) {
130
+		if( $max !== null && ( (float) $max ) < $basketWeight ) {
131 131
 			return false;
132 132
 		}
133 133
 
@@ -156,7 +156,7 @@  discard block
 block discarded – undo
156 156
 		foreach( $manager->searchItems( $search, ['product/property'] ) as $product )
157 157
 		{
158 158
 			foreach( $product->getPropertyItems( 'package-weight' ) as $property ) {
159
-				$weight += ((float) $property->getValue()) * $prodMap[$product->getCode()];
159
+				$weight += ( (float) $property->getValue() ) * $prodMap[$product->getCode()];
160 160
 			}
161 161
 		}
162 162
 
Please login to merge, or discard this patch.