Passed
Push — master ( 96cc40...534161 )
by Aimeos
01:56
created
jobs/tests/Controller/Jobs/Catalog/Export/Sitemap/FactoryTest.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -17,7 +17,7 @@
 block discarded – undo
17 17
 		$aimeos = \TestHelperJobs::getAimeos();
18 18
 
19 19
 		$obj = \Aimeos\Controller\Jobs\Catalog\Export\Sitemap\Factory::create( $context, $aimeos );
20
-		$this->assertInstanceOf( '\\Aimeos\\Controller\\Jobs\\Iface', $obj);
20
+		$this->assertInstanceOf( '\\Aimeos\\Controller\\Jobs\\Iface', $obj );
21 21
 	}
22 22
 
23 23
 
Please login to merge, or discard this patch.
controller/jobs/src/Controller/Jobs/Catalog/Export/Sitemap/Standard.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -196,10 +196,10 @@  discard block
 block discarded – undo
196 196
 		 * @see controller/jobs/catalog/export/sitemap/max-query
197 197
 		 * @see controller/jobs/catalog/export/sitemap/changefreq
198 198
 		 */
199
-		$default = array('gzip-mode' => 'wb');
199
+		$default = array( 'gzip-mode' => 'wb' );
200 200
 		$options = $config->get( 'controller/jobs/catalog/export/sitemap/container/options', $default );
201 201
 
202
-		if ( $location === null || $location === '' ) {
202
+		if( $location === null || $location === '' ) {
203 203
 			$msg = sprintf( 'Required configuration for "%1$s" is missing', 'controller/jobs/catalog/export/sitemap/location' );
204 204
 			throw new \Aimeos\Controller\Jobs\Exception( $msg );
205 205
 		}
@@ -420,7 +420,7 @@  discard block
 block discarded – undo
420 420
 		$manager = \Aimeos\MShop::create( $this->getContext(), 'catalog' );
421 421
 
422 422
 		$search = $manager->createSearch( $default );
423
-		$search->setSortations( array($search->sort( '+', 'catalog.id' )) );
423
+		$search->setSortations( array( $search->sort( '+', 'catalog.id' ) ) );
424 424
 		$search->setSlice( 0, $maxQuery );
425 425
 
426 426
 		$content = $this->createContent( $container, $filenum );
Please login to merge, or discard this patch.
common/src/Controller/Common/Product/Import/Csv/Cache/Product/Standard.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -70,6 +70,6 @@
 block discarded – undo
70 70
 	 */
71 71
 	public function set( \Aimeos\MShop\Common\Item\Iface $item )
72 72
 	{
73
-		$this->prodmap[ $item->getCode() ] = $item->getId();
73
+		$this->prodmap[$item->getCode()] = $item->getId();
74 74
 	}
75 75
 }
Please login to merge, or discard this patch.
common/src/Controller/Common/Product/Import/Csv/Cache/Catalog/Standard.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -48,7 +48,7 @@  discard block
 block discarded – undo
48 48
 		$result = $manager->searchItems( $manager->createSearch() );
49 49
 
50 50
 		foreach( $result as $id => $item ) {
51
-			$this->categories[ $item->getCode() ] = $id;
51
+			$this->categories[$item->getCode()] = $id;
52 52
 		}
53 53
 	}
54 54
 
@@ -88,6 +88,6 @@  discard block
 block discarded – undo
88 88
 	 */
89 89
 	public function set( \Aimeos\MShop\Common\Item\Iface $item )
90 90
 	{
91
-		$this->categories[ $item->getCode() ] = $item->getId();
91
+		$this->categories[$item->getCode()] = $item->getId();
92 92
 	}
93 93
 }
Please login to merge, or discard this patch.
src/Controller/Common/Product/Import/Csv/Cache/Attribute/Standard.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -48,7 +48,7 @@  discard block
 block discarded – undo
48 48
 		$result = $manager->searchItems( $manager->createSearch() );
49 49
 
50 50
 		foreach( $result as $id => $item ) {
51
-			$this->attributes[ $item->getCode() ][ $item->getType() ] = $item;
51
+			$this->attributes[$item->getCode()][$item->getType()] = $item;
52 52
 		}
53 53
 	}
54 54
 
@@ -98,6 +98,6 @@  discard block
 block discarded – undo
98 98
 			$this->attributes[$code] = [];
99 99
 		}
100 100
 
101
-		$this->attributes[$code][ $item->getType() ] = $item;
101
+		$this->attributes[$code][$item->getType()] = $item;
102 102
 	}
103 103
 }
Please login to merge, or discard this patch.
controller/jobs/templates/product/export/items-body-standard.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -22,7 +22,7 @@  discard block
 block discarded – undo
22 22
 			<list>
23 23
 				<text>
24 24
 					<?php foreach( $item->getListItems( 'text' ) as $listItem ) : ?>
25
-						<?php if ( $refItem = $listItem->getRefItem() ) { ?>
25
+						<?php if( $refItem = $listItem->getRefItem() ) { ?>
26 26
 							<textitem id="<?php echo $enc->attr( $refItem->getId() ); ?>" siteid="<?php echo $enc->attr( $refItem->getSiteId() ); ?>" ctime="<?php echo $enc->attr( $refItem->getTimeCreated() ); ?>" mtime="<?php echo $enc->attr( $refItem->getTimeModified() ); ?>" editor="<?php echo $enc->attr( $refItem->getEditor() ); ?>" list.id="<?php echo $enc->attr( $listItem->getId() ); ?>" list.siteid="<?php echo $enc->attr( $listItem->getSiteId() ); ?>" list.parentid="<?php echo $enc->attr( $listItem->getParentId() ); ?>" list.type="<?php echo $enc->attr( $listItem->getType() ); ?>" list.domain="<?php echo $enc->attr( $listItem->getDomain() ); ?>" list.config="<?php echo $enc->attr( json_encode( $listItem->getConfig() ) ); ?>" list.start="<?php echo $enc->attr( $listItem->getDateStart() ); ?>" list.end="<?php echo $enc->attr( $listItem->getDateEnd() ); ?>" list.position="<?php echo $enc->attr( $listItem->getPosition() ); ?>" list.status="<?php echo $enc->attr( $listItem->getStatus() ); ?>" list.ctime="<?php echo $enc->attr( $listItem->getTimeCreated() ); ?>" list.mtime="<?php echo $enc->attr( $listItem->getTimeModified() ); ?>" list.editor="<?php echo $enc->attr( $listItem->getEditor() ); ?>">
27 27
 								<type><![CDATA[<?php echo $refItem->getType(); ?>]]></type>
28 28
 								<languageid><![CDATA[<?php echo $refItem->getLanguageId(); ?>]]></languageid>
@@ -36,7 +36,7 @@  discard block
 block discarded – undo
36 36
 				</text>
37 37
 				<media>
38 38
 					<?php foreach( $item->getListItems( 'media' ) as $listItem ) : ?>
39
-						<?php if ( $refItem = $listItem->getRefItem() ) { ?>
39
+						<?php if( $refItem = $listItem->getRefItem() ) { ?>
40 40
 							<mediaitem id="<?php echo $enc->attr( $refItem->getId() ); ?>" siteid="<?php echo $enc->attr( $refItem->getSiteId() ); ?>" ctime="<?php echo $enc->attr( $refItem->getTimeCreated() ); ?>" mtime="<?php echo $enc->attr( $refItem->getTimeModified() ); ?>" editor="<?php echo $enc->attr( $refItem->getEditor() ); ?>" list.id="<?php echo $enc->attr( $listItem->getId() ); ?>" list.siteid="<?php echo $enc->attr( $listItem->getSiteId() ); ?>" list.parentid="<?php echo $enc->attr( $listItem->getParentId() ); ?>" list.type="<?php echo $enc->attr( $listItem->getType() ); ?>" list.config="<?php echo $enc->attr( json_encode( $listItem->getConfig() ) ); ?>" list.start="<?php echo $enc->attr( $listItem->getDateStart() ); ?>" list.end="<?php echo $enc->attr( $listItem->getDateEnd() ); ?>" list.position="<?php echo $enc->attr( $listItem->getPosition() ); ?>" list.status="<?php echo $enc->attr( $listItem->getStatus() ); ?>" list.ctime="<?php echo $enc->attr( $listItem->getTimeCreated() ); ?>" list.mtime="<?php echo $enc->attr( $listItem->getTimeModified() ); ?>" list.editor="<?php echo $enc->attr( $listItem->getEditor() ); ?>">
41 41
 								<type><![CDATA[<?php echo $refItem->getType(); ?>]]></type>
42 42
 								<languageid><![CDATA[<?php echo $refItem->getLanguageId(); ?>]]></languageid>
@@ -52,7 +52,7 @@  discard block
 block discarded – undo
52 52
 				</media>
53 53
 				<price>
54 54
 					<?php foreach( $item->getListItems( 'price' ) as $listItem ) : ?>
55
-						<?php if ( $refItem = $listItem->getRefItem() ) { ?>
55
+						<?php if( $refItem = $listItem->getRefItem() ) { ?>
56 56
 							<priceitem id="<?php echo $enc->attr( $refItem->getId() ); ?>" siteid="<?php echo $enc->attr( $refItem->getSiteId() ); ?>" ctime="<?php echo $enc->attr( $refItem->getTimeCreated() ); ?>" mtime="<?php echo $enc->attr( $refItem->getTimeModified() ); ?>" editor="<?php echo $enc->attr( $refItem->getEditor() ); ?>" list.id="<?php echo $enc->attr( $listItem->getId() ); ?>" list.siteid="<?php echo $enc->attr( $listItem->getSiteId() ); ?>" list.parentid="<?php echo $enc->attr( $listItem->getParentId() ); ?>" list.type="<?php echo $enc->attr( $listItem->getType() ); ?>" list.config="<?php echo $enc->attr( json_encode( $listItem->getConfig() ) ); ?>" list.start="<?php echo $enc->attr( $listItem->getDateStart() ); ?>" list.end="<?php echo $enc->attr( $listItem->getDateEnd() ); ?>" list.position="<?php echo $enc->attr( $listItem->getPosition() ); ?>" list.status="<?php echo $enc->attr( $listItem->getStatus() ); ?>" list.ctime="<?php echo $enc->attr( $listItem->getTimeCreated() ); ?>" list.mtime="<?php echo $enc->attr( $listItem->getTimeModified() ); ?>" list.editor="<?php echo $enc->attr( $listItem->getEditor() ); ?>">
57 57
 								<type><![CDATA[<?php echo $refItem->getType(); ?>]]></type>
58 58
 								<currencyid><![CDATA[<?php echo $refItem->getCurrencyId(); ?>]]></currencyid>
@@ -70,7 +70,7 @@  discard block
 block discarded – undo
70 70
 				</price>
71 71
 				<attribute>
72 72
 					<?php foreach( $item->getListItems( 'attribute' ) as $listItem ) : ?>
73
-						<?php if ( $refItem = $listItem->getRefItem() ) { ?>
73
+						<?php if( $refItem = $listItem->getRefItem() ) { ?>
74 74
 							<attributeitem id="<?php echo $enc->attr( $refItem->getId() ); ?>" siteid="<?php echo $enc->attr( $refItem->getSiteId() ); ?>" ctime="<?php echo $enc->attr( $refItem->getTimeCreated() ); ?>" mtime="<?php echo $enc->attr( $refItem->getTimeModified() ); ?>" editor="<?php echo $enc->attr( $refItem->getEditor() ); ?>" list.id="<?php echo $enc->attr( $listItem->getId() ); ?>" list.siteid="<?php echo $enc->attr( $listItem->getSiteId() ); ?>" list.parentid="<?php echo $enc->attr( $listItem->getParentId() ); ?>" list.type="<?php echo $enc->attr( $listItem->getType() ); ?>" list.config="<?php echo $enc->attr( json_encode( $listItem->getConfig() ) ); ?>" list.start="<?php echo $enc->attr( $listItem->getDateStart() ); ?>" list.end="<?php echo $enc->attr( $listItem->getDateEnd() ); ?>" list.position="<?php echo $enc->attr( $listItem->getPosition() ); ?>" list.status="<?php echo $enc->attr( $listItem->getStatus() ); ?>" list.ctime="<?php echo $enc->attr( $listItem->getTimeCreated() ); ?>" list.mtime="<?php echo $enc->attr( $listItem->getTimeModified() ); ?>" list.editor="<?php echo $enc->attr( $listItem->getEditor() ); ?>">
75 75
 								<type><![CDATA[<?php echo $refItem->getType(); ?>]]></type>
76 76
 								<code><![CDATA[<?php echo $refItem->getCode(); ?>]]></code>
@@ -84,7 +84,7 @@  discard block
 block discarded – undo
84 84
 				</attribute>
85 85
 				<product>
86 86
 					<?php foreach( $item->getListItems( 'product' ) as $listItem ) : ?>
87
-						<?php if ( $refItem = $listItem->getRefItem() ) { ?>
87
+						<?php if( $refItem = $listItem->getRefItem() ) { ?>
88 88
 							<productitem id="<?php echo $enc->attr( $refItem->getId() ); ?>" siteid="<?php echo $enc->attr( $refItem->getSiteId() ); ?>" ctime="<?php echo $enc->attr( $refItem->getTimeCreated() ); ?>" mtime="<?php echo $enc->attr( $refItem->getTimeModified() ); ?>" editor="<?php echo $enc->attr( $refItem->getEditor() ); ?>" list.id="<?php echo $enc->attr( $listItem->getId() ); ?>" list.siteid="<?php echo $enc->attr( $listItem->getSiteId() ); ?>" list.parentid="<?php echo $enc->attr( $listItem->getParentId() ); ?>" list.type="<?php echo $enc->attr( $listItem->getType() ); ?>" list.config="<?php echo $enc->attr( json_encode( $listItem->getConfig() ) ); ?>" list.start="<?php echo $enc->attr( $listItem->getDateStart() ); ?>" list.end="<?php echo $enc->attr( $listItem->getDateEnd() ); ?>" list.position="<?php echo $enc->attr( $listItem->getPosition() ); ?>" list.status="<?php echo $enc->attr( $listItem->getStatus() ); ?>" list.ctime="<?php echo $enc->attr( $listItem->getTimeCreated() ); ?>" list.mtime="<?php echo $enc->attr( $listItem->getTimeModified() ); ?>" list.editor="<?php echo $enc->attr( $listItem->getEditor() ); ?>">
89 89
 								<type><![CDATA[<?php echo $item->getType(); ?>]]></type>
90 90
 								<code><![CDATA[<?php echo $item->getCode(); ?>]]></code>
Please login to merge, or discard this patch.
src/Controller/Common/Common/Import/Xml/Processor/Property/Standard.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -67,7 +67,7 @@
 block discarded – undo
67 67
 			$propItem = $manager->createItem()->fromArray( $list );
68 68
 
69 69
 			if( isset( $map[$propItem->getType()][$propItem->getLanguageId()][$propItem->getValue()] ) ) {
70
-				unset( $propItems[ $map[$propItem->getType()][$propItem->getLanguageId()][$propItem->getValue()] ] );
70
+				unset( $propItems[$map[$propItem->getType()][$propItem->getLanguageId()][$propItem->getValue()]] );
71 71
 			} else {
72 72
 				$item->addPropertyItem( $propItem );
73 73
 			}
Please login to merge, or discard this patch.
controller/common/src/Controller/Common/Common/Import/Xml/Traits.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -52,7 +52,7 @@  discard block
 block discarded – undo
52 52
 
53 53
 		if( ctype_alnum( $type ) === false )
54 54
 		{
55
-			$classname = is_string($type) ? '\\Aimeos\\Controller\\Common\\Common\\Import\\Xml\\Processor\\' . $type : '<not a string>';
55
+			$classname = is_string( $type ) ? '\\Aimeos\\Controller\\Common\\Common\\Import\\Xml\\Processor\\' . $type : '<not a string>';
56 56
 			throw new \Aimeos\Controller\Common\Exception( sprintf( 'Invalid characters in class name "%1$s"', $classname ) );
57 57
 		}
58 58
 
@@ -60,7 +60,7 @@  discard block
 block discarded – undo
60 60
 
61 61
 		if( ctype_alnum( $name ) === false )
62 62
 		{
63
-			$classname = is_string($name) ? '\\Aimeos\\Controller\\Common\\Common\\Import\\Xml\\Processor\\' . $type . '\\' . $name : '<not a string>';
63
+			$classname = is_string( $name ) ? '\\Aimeos\\Controller\\Common\\Common\\Import\\Xml\\Processor\\' . $type . '\\' . $name : '<not a string>';
64 64
 			throw new \Aimeos\Controller\Common\Exception( sprintf( 'Invalid characters in class name "%1$s"', $classname ) );
65 65
 		}
66 66
 
Please login to merge, or discard this patch.
controller/common/src/Controller/Common/Product/Import/Csv/Base.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -57,7 +57,7 @@  discard block
 block discarded – undo
57 57
 
58 58
 		if( ctype_alnum( $type ) === false )
59 59
 		{
60
-			$classname = is_string($name) ? '\\Aimeos\\Controller\\Common\\Product\\Import\\Csv\\Cache\\' . $type : '<not a string>';
60
+			$classname = is_string( $name ) ? '\\Aimeos\\Controller\\Common\\Product\\Import\\Csv\\Cache\\' . $type : '<not a string>';
61 61
 			throw new \Aimeos\Controller\Common\Exception( sprintf( 'Invalid characters in class name "%1$s"', $classname ) );
62 62
 		}
63 63
 
@@ -67,7 +67,7 @@  discard block
 block discarded – undo
67 67
 
68 68
 		if( ctype_alnum( $name ) === false )
69 69
 		{
70
-			$classname = is_string($name) ? '\\Aimeos\\Controller\\Common\\Product\\Import\\Csv\\Cache\\' . $type . '\\' . $name : '<not a string>';
70
+			$classname = is_string( $name ) ? '\\Aimeos\\Controller\\Common\\Product\\Import\\Csv\\Cache\\' . $type . '\\' . $name : '<not a string>';
71 71
 			throw new \Aimeos\Controller\Common\Exception( sprintf( 'Invalid characters in class name "%1$s"', $classname ) );
72 72
 		}
73 73
 
@@ -119,7 +119,7 @@  discard block
 block discarded – undo
119 119
 		while( $content->valid() && $count++ < $maxcnt )
120 120
 		{
121 121
 			$row = $content->current();
122
-			$data[ $row[$codePos] ] = $row;
122
+			$data[$row[$codePos]] = $row;
123 123
 			$content->next();
124 124
 		}
125 125
 
@@ -256,7 +256,7 @@  discard block
 block discarded – undo
256 256
 		{
257 257
 			if( ctype_alnum( $type ) === false )
258 258
 			{
259
-				$classname = is_string($type) ? '\\Aimeos\\Controller\\Common\\Product\\Import\\Csv\\Processor\\' . $type : '<not a string>';
259
+				$classname = is_string( $type ) ? '\\Aimeos\\Controller\\Common\\Product\\Import\\Csv\\Processor\\' . $type : '<not a string>';
260 260
 				throw new \Aimeos\Controller\Common\Exception( sprintf( 'Invalid characters in class name "%1$s"', $classname ) );
261 261
 			}
262 262
 
@@ -264,7 +264,7 @@  discard block
 block discarded – undo
264 264
 
265 265
 			if( ctype_alnum( $name ) === false )
266 266
 			{
267
-				$classname = is_string($name) ? '\\Aimeos\\Controller\\Common\\Product\\Import\\Csv\\Processor\\' . $type . '\\' . $name : '<not a string>';
267
+				$classname = is_string( $name ) ? '\\Aimeos\\Controller\\Common\\Product\\Import\\Csv\\Processor\\' . $type . '\\' . $name : '<not a string>';
268 268
 				throw new \Aimeos\Controller\Common\Exception( sprintf( 'Invalid characters in class name "%1$s"', $classname ) );
269 269
 			}
270 270
 
@@ -300,7 +300,7 @@  discard block
 block discarded – undo
300 300
 		$search->setSlice( 0, count( $codes ) );
301 301
 
302 302
 		foreach( $manager->searchItems( $search, $domains ) as $item ) {
303
-			$result[ $item->getCode() ] = $item;
303
+			$result[$item->getCode()] = $item;
304 304
 		}
305 305
 
306 306
 		return $result;
Please login to merge, or discard this patch.