Passed
Push — master ( 8def93...32ad9a )
by Aimeos
02:40
created
templates/client/jsonapi/attribute/standard.php 1 patch
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -37,8 +37,7 @@  discard block
 block discarded – undo
37 37
 }
38 38
 
39 39
 
40
-$entryFcn = function( \Aimeos\MShop\Attribute\Item\Iface $item ) use ( $fields, $target, $cntl, $action, $config )
41
-{
40
+$entryFcn = function( \Aimeos\MShop\Attribute\Item\Iface $item ) use ( $fields, $target, $cntl, $action, $config ) {
42 41
 	$id = $item->getId();
43 42
 	$type = $item->getResourceType();
44 43
 	$params = array( 'resource' => $type, 'id' => $id );
@@ -129,8 +128,7 @@  discard block
 block discarded – undo
129 128
 				foreach( $items as $item ) {
130 129
 					$data[] = $entryFcn( $item );
131 130
 				}
132
-			}
133
-			else
131
+			} else
134 132
 			{
135 133
 				$data = $entryFcn( $items );
136 134
 			}
Please login to merge, or discard this patch.
templates/client/jsonapi/service/standard.php 1 patch
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -27,8 +27,7 @@  discard block
 block discarded – undo
27 27
 }
28 28
 
29 29
 
30
-$entryFcn = function( \Aimeos\MShop\Service\Item\Iface $item, \Aimeos\Map $prices, array $feConfig ) use ( $fields, $target, $cntl, $action, $config )
31
-{
30
+$entryFcn = function( \Aimeos\MShop\Service\Item\Iface $item, \Aimeos\Map $prices, array $feConfig ) use ( $fields, $target, $cntl, $action, $config ) {
32 31
 	$metadata = [];
33 32
 	$id = $item->getId();
34 33
 	$type = $item->getResourceType();
@@ -121,8 +120,7 @@  discard block
 block discarded – undo
121 120
 				foreach( $items as $item ) {
122 121
 					$data[] = $entryFcn( $item, $prices, $feConfig );
123 122
 				}
124
-			}
125
-			else
123
+			} else
126 124
 			{
127 125
 				$data = $entryFcn( $items, $prices, $feConfig );
128 126
 			}
Please login to merge, or discard this patch.
templates/client/jsonapi/customer/relationships/standard.php 1 patch
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -27,8 +27,7 @@  discard block
 block discarded – undo
27 27
 }
28 28
 
29 29
 
30
-$entryFcn = function( \Aimeos\MShop\Common\Item\Lists\Iface $item ) use ( $fields, $target, $cntl, $action, $config )
31
-{
30
+$entryFcn = function( \Aimeos\MShop\Common\Item\Lists\Iface $item ) use ( $fields, $target, $cntl, $action, $config ) {
32 31
 	$relid = $item->getId();
33 32
 	$id = $item->getParentId();
34 33
 	$attributes = $item->toArray();
@@ -86,8 +85,7 @@  discard block
 block discarded – undo
86 85
 				foreach( $items as $item ) {
87 86
 					$data[] = $entryFcn( $item );
88 87
 				}
89
-			}
90
-			else
88
+			} else
91 89
 			{
92 90
 				$data = $entryFcn( $items );
93 91
 			}
Please login to merge, or discard this patch.
templates/client/jsonapi/customer/standard.php 1 patch
Braces   +3 added lines, -6 removed lines patch added patch discarded remove patch
@@ -27,8 +27,7 @@  discard block
 block discarded – undo
27 27
 }
28 28
 
29 29
 
30
-$entryFcn = function( \Aimeos\MShop\Customer\Item\Iface $item ) use ( $fields, $target, $cntl, $action, $config )
31
-{
30
+$entryFcn = function( \Aimeos\MShop\Customer\Item\Iface $item ) use ( $fields, $target, $cntl, $action, $config ) {
32 31
 	$id = $item->getId();
33 32
 	$type = $item->getResourceType();
34 33
 	$params = array( 'resource' => $type, 'id' => $id );
@@ -91,8 +90,7 @@  discard block
 block discarded – undo
91 90
 };
92 91
 
93 92
 
94
-$custAddrFcn = function( \Aimeos\MShop\Customer\Item\Address\Iface $item, array $entry ) use ( $target, $cntl, $action, $config )
95
-{
93
+$custAddrFcn = function( \Aimeos\MShop\Customer\Item\Address\Iface $item, array $entry ) use ( $target, $cntl, $action, $config ) {
96 94
 	$params = ['resource' => 'customer', 'id' => $item->getParentId(), 'related' => 'address', 'relatedid' => $item->getId()];
97 95
 	$basketParams = ['resource' => 'basket', 'id' => 'default', 'related' => 'address', 'relatedid' => 'payment'];
98 96
 
@@ -111,8 +109,7 @@  discard block
 block discarded – undo
111 109
 };
112 110
 
113 111
 
114
-$custPropFcn = function( \Aimeos\MShop\Common\Item\Property\Iface $item, array $entry ) use ( $target, $cntl, $action, $config )
115
-{
112
+$custPropFcn = function( \Aimeos\MShop\Common\Item\Property\Iface $item, array $entry ) use ( $target, $cntl, $action, $config ) {
116 113
 	$params = ['resource' => 'customer', 'id' => $item->getParentId(), 'related' => 'property', 'relatedid' => $item->getId()];
117 114
 
118 115
 	$entry['links'] = [
Please login to merge, or discard this patch.
templates/client/jsonapi/site/standard.php 1 patch
Braces   +3 added lines, -6 removed lines patch added patch discarded remove patch
@@ -29,8 +29,7 @@  discard block
 block discarded – undo
29 29
 }
30 30
 
31 31
 
32
-$entryFcn = function( \Aimeos\MShop\Locale\Item\Site\Iface $item ) use ( $fields, $target, $cntl, $action, $config )
33
-{
32
+$entryFcn = function( \Aimeos\MShop\Locale\Item\Site\Iface $item ) use ( $fields, $target, $cntl, $action, $config ) {
34 33
 	if( $item->isAvailable() === false ) {
35 34
 		return [];
36 35
 	}
@@ -67,8 +66,7 @@  discard block
 block discarded – undo
67 66
 };
68 67
 
69 68
 
70
-$siteFcn = function( \Aimeos\MShop\Locale\Item\Site\Iface $item, array $entry ) use ( $target, $cntl, $action, $config )
71
-{
69
+$siteFcn = function( \Aimeos\MShop\Locale\Item\Site\Iface $item, array $entry ) use ( $target, $cntl, $action, $config ) {
72 70
 	$params = ['resource' => 'site', 'id' => $item->getId()];
73 71
 	$entry['links'] = [
74 72
 		'self' => [
@@ -112,8 +110,7 @@  discard block
 block discarded – undo
112 110
 				foreach( $items as $item ) {
113 111
 					$data[] = $entryFcn( $item );
114 112
 				}
115
-			}
116
-			else
113
+			} else
117 114
 			{
118 115
 				$data = $entryFcn( $items );
119 116
 			}
Please login to merge, or discard this patch.
templates/client/jsonapi/product/standard.php 1 patch
Braces   +3 added lines, -6 removed lines patch added patch discarded remove patch
@@ -103,8 +103,7 @@  discard block
 block discarded – undo
103 103
 }
104 104
 
105 105
 
106
-$entryFcn = function( \Aimeos\MShop\Product\Item\Iface $item ) use ( $fields, $target, $cntl, $action, $config )
107
-{
106
+$entryFcn = function( \Aimeos\MShop\Product\Item\Iface $item ) use ( $fields, $target, $cntl, $action, $config ) {
108 107
 	$id = $item->getId();
109 108
 	$attributes = $item->toArray();
110 109
 	$type = $item->getResourceType();
@@ -166,8 +165,7 @@  discard block
 block discarded – undo
166 165
 };
167 166
 
168 167
 
169
-$includeFcn = function( \Aimeos\MShop\Product\Item\Iface $item ) use ( $fields, $target, $cntl, $action, $config )
170
-{
168
+$includeFcn = function( \Aimeos\MShop\Product\Item\Iface $item ) use ( $fields, $target, $cntl, $action, $config ) {
171 169
 	$result = [];
172 170
 
173 171
 	foreach( $item->getStockItems() as $id => $stockItem )
@@ -242,8 +240,7 @@  discard block
 block discarded – undo
242 240
 					$data[] = $entryFcn( $item );
243 241
 					$included = array_replace_recursive( $included, $includeFcn( $item ) );
244 242
 				}
245
-			}
246
-			else
243
+			} else
247 244
 			{
248 245
 				$data = $entryFcn( $items );
249 246
 				$included = array_replace_recursive( $included, $includeFcn( $items ) );
Please login to merge, or discard this patch.
templates/client/jsonapi/stock/standard.php 1 patch
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -35,8 +35,7 @@  discard block
 block discarded – undo
35 35
 }
36 36
 
37 37
 
38
-$entryFcn = function( \Aimeos\MShop\Stock\Item\Iface $item ) use ( $fields, $target, $cntl, $action, $config )
39
-{
38
+$entryFcn = function( \Aimeos\MShop\Stock\Item\Iface $item ) use ( $fields, $target, $cntl, $action, $config ) {
40 39
 	$id = $item->getId();
41 40
 	$type = $item->getResourceType();
42 41
 	$params = array( 'resource' => $type, 'id' => $id );
@@ -111,8 +110,7 @@  discard block
 block discarded – undo
111 110
 				foreach( $items as $item ) {
112 111
 					$data[] = $entryFcn( $item );
113 112
 				}
114
-			}
115
-			else
113
+			} else
116 114
 			{
117 115
 				$data = $entryFcn( $items );
118 116
 			}
Please login to merge, or discard this patch.
src/Base/View/Helper/Jincluded/Standard.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -39,8 +39,7 @@
 block discarded – undo
39 39
 			foreach( $item as $entry ) {
40 40
 				$this->entry( $entry, $fields, $fcn );
41 41
 			}
42
-		}
43
-		else
42
+		} else
44 43
 		{
45 44
 			$this->entry( $item, $fields, $fcn );
46 45
 		}
Please login to merge, or discard this patch.
templates/client/jsonapi/order/standard.php 1 patch
Braces   +7 added lines, -14 removed lines patch added patch discarded remove patch
@@ -26,8 +26,7 @@  discard block
 block discarded – undo
26 26
 }
27 27
 
28 28
 
29
-$entryFcn = function( \Aimeos\MShop\Order\Item\Iface $item, \Aimeos\MShop\Common\Helper\Form\Iface $form = null ) use ( $fields, $target, $cntl, $action, $config )
30
-{
29
+$entryFcn = function( \Aimeos\MShop\Order\Item\Iface $item, \Aimeos\MShop\Common\Helper\Form\Iface $form = null ) use ( $fields, $target, $cntl, $action, $config ) {
31 30
 	$relationships = [];
32 31
 	$id = $item->getId();
33 32
 	$attributes = $item->toArray();
@@ -92,8 +91,7 @@  discard block
 block discarded – undo
92 91
 };
93 92
 
94 93
 
95
-$productFcn = function( \Aimeos\MShop\Order\Item\Iface $item ) use ( $fields )
96
-{
94
+$productFcn = function( \Aimeos\MShop\Order\Item\Iface $item ) use ( $fields ) {
97 95
 	$result = [];
98 96
 
99 97
 	foreach( $item->getProducts() as $orderProduct )
@@ -133,8 +131,7 @@  discard block
 block discarded – undo
133 131
 };
134 132
 
135 133
 
136
-$serviceFcn = function( \Aimeos\MShop\Order\Item\Iface $item ) use ( $fields )
137
-{
134
+$serviceFcn = function( \Aimeos\MShop\Order\Item\Iface $item ) use ( $fields ) {
138 135
 	$result = [];
139 136
 
140 137
 	foreach( $item->getServices() as $type => $list )
@@ -166,8 +163,7 @@  discard block
 block discarded – undo
166 163
 };
167 164
 
168 165
 
169
-$addressFcn = function( \Aimeos\MShop\Order\Item\Iface $item ) use ( $fields )
170
-{
166
+$addressFcn = function( \Aimeos\MShop\Order\Item\Iface $item ) use ( $fields ) {
171 167
 	$list = [];
172 168
 
173 169
 	foreach( $item->getAddresses() as $type => $addresses )
@@ -189,8 +185,7 @@  discard block
 block discarded – undo
189 185
 };
190 186
 
191 187
 
192
-$couponFcn = function( \Aimeos\MShop\Order\Item\Iface $item )
193
-{
188
+$couponFcn = function( \Aimeos\MShop\Order\Item\Iface $item ) {
194 189
 	$coupons = [];
195 190
 
196 191
 	foreach( $item->getCoupons() as $code => $list ) {
@@ -201,8 +196,7 @@  discard block
 block discarded – undo
201 196
 };
202 197
 
203 198
 
204
-$customerFcn = function( \Aimeos\MShop\Order\Item\Iface $item ) use ( $fields, $target, $cntl, $action, $config )
205
-{
199
+$customerFcn = function( \Aimeos\MShop\Order\Item\Iface $item ) use ( $fields, $target, $cntl, $action, $config ) {
206 200
 	$result = [];
207 201
 
208 202
 	if( ( $customer = $item->getCustomerItem() ) !== null && $customer->isAvailable() )
@@ -266,8 +260,7 @@  discard block
 block discarded – undo
266 260
 					$included = array_replace_recursive( $included, $serviceFcn( $item ) );
267 261
 					$included = array_replace_recursive( $included, $customerFcn( $item ) );
268 262
 				}
269
-			}
270
-			else
263
+			} else
271 264
 			{
272 265
 				$data = $entryFcn( $items, $this->get( 'form' ) );
273 266
 				$included = array_replace_recursive( $included, $couponFcn( $items ) );
Please login to merge, or discard this patch.