Completed
Push — master ( 815faa...197710 )
by Aimeos
07:55
created
lib/mshoplib/src/MShop/Common/Item/ListRef/Base.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -116,7 +116,7 @@
 block discarded – undo
116 116
 	 *
117 117
 	 * @param string|null $domain Name of the domain (e.g. product, text, etc.) or null for all
118 118
 	 * @param array|string|null $type Name/Names of the item type or null for all
119
-	 * @param array|string|null $listtype Name/Names of the list item type or null for all
119
+	 * @param string $listtype Name/Names of the list item type or null for all
120 120
 	 * @return array List of items implementing \Aimeos\MShop\Common\Item\Iface
121 121
 	 */
122 122
 	public function getRefItems( $domain = null, $type = null, $listtype = null )
Please login to merge, or discard this patch.
lib/mshoplib/src/MShop/Service/Manager/Standard.php 3 patches
Doc Comments   +1 added lines patch added patch discarded remove patch
@@ -410,6 +410,7 @@
 block discarded – undo
410 410
 	 * @param \Aimeos\MW\Criteria\Iface $search Search criteria object
411 411
 	 * @param array $ref List of domains to fetch list items and referenced items for
412 412
 	 * @param integer &$total Number of items that are available in total
413
+	 * @param integer $total
413 414
 	 * @return array List of service items implementing \Aimeos\MShop\Service\Item\Iface
414 415
 	 *
415 416
 	 * @throws \Aimeos\MShop\Service\Exception if creating items failed
Please login to merge, or discard this patch.
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -226,8 +226,7 @@
 block discarded – undo
226 226
 
227 227
 					$params[] = implode( ',', $list );
228 228
 				}
229
-			}
230
-			else
229
+			} else
231 230
 			{
232 231
 				$params[] = $this->escape( '==', $this->getParamType( $string ), $string );
233 232
 			}
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -651,7 +651,7 @@  discard block
 block discarded – undo
651 651
 		}
652 652
 
653 653
 		$interface = '\\Aimeos\\MShop\\Service\\Provider\\Factory\\Iface';
654
-		$classname = '\\Aimeos\\MShop\\Service\\Provider\\' . $type . '\\' . $provider;
654
+		$classname = '\\Aimeos\\MShop\\Service\\Provider\\'.$type.'\\'.$provider;
655 655
 
656 656
 		if( class_exists( $classname ) === false ) {
657 657
 			throw new \Aimeos\MShop\Service\Exception( sprintf( 'Class "%1$s" not available', $classname ) );
@@ -712,7 +712,7 @@  discard block
 block discarded – undo
712 712
 		 * @category Developer
713 713
 		 * @see mshop/service/provider/delivery/decorators
714 714
 		 */
715
-		$decorators = $config->get( 'mshop/service/provider/' . $item->getType() . '/decorators', array() );
715
+		$decorators = $config->get( 'mshop/service/provider/'.$item->getType().'/decorators', array() );
716 716
 
717 717
 		$provider = $this->addServiceDecorators( $item, $provider, $names );
718 718
 		return $this->addServiceDecorators( $item, $provider, $decorators );
Please login to merge, or discard this patch.
controller/jobs/src/Controller/Jobs/Factory.php 2 patches
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -136,8 +136,7 @@
 block discarded – undo
136 136
 				$subList = self::createControllers( $it, $context, $aimeos, $pref );
137 137
 
138 138
 				$list = array_merge( $list, $subList );
139
-			}
140
-			else if( $prefix !== '' && $entry->getType() === 'file'
139
+			} else if( $prefix !== '' && $entry->getType() === 'file'
141 140
 				&& ( $name = $entry->getBaseName( '.php' ) ) === 'Factory' )
142 141
 			{
143 142
 				$list[$prefix] = self::createController( $context, $aimeos, $prefix );
Please login to merge, or discard this patch.
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -56,7 +56,7 @@  discard block
 block discarded – undo
56 56
 			$parts[$key] = ucwords( $part );
57 57
 		}
58 58
 
59
-		$factory = '\\Aimeos\\Controller\\Jobs\\' . join( '\\', $parts ) . '\\Factory';
59
+		$factory = '\\Aimeos\\Controller\\Jobs\\'.join( '\\', $parts ).'\\Factory';
60 60
 
61 61
 		if( class_exists( $factory ) === false ) {
62 62
 			throw new \Aimeos\Controller\Jobs\Exception( sprintf( 'Class "%1$s" not found', $factory ) );
@@ -86,7 +86,7 @@  discard block
 block discarded – undo
86 86
 		$cntlList = array();
87 87
 		$subFolder = trim( str_replace( '\\', '/', self::$prefix ), '/' );
88 88
 
89
-		if( strncmp( $subFolder, 'Aimeos' . '/', 7 ) === 0 ) {
89
+		if( strncmp( $subFolder, 'Aimeos'.'/', 7 ) === 0 ) {
90 90
 			$subFolder = substr( $subFolder, 7 );
91 91
 		}
92 92
 
@@ -94,7 +94,7 @@  discard block
 block discarded – undo
94 94
 		{
95 95
 			foreach( $list as $relpath )
96 96
 			{
97
-				$path .= DIRECTORY_SEPARATOR . str_replace( '/', DIRECTORY_SEPARATOR, $relpath . '/' . $subFolder );
97
+				$path .= DIRECTORY_SEPARATOR.str_replace( '/', DIRECTORY_SEPARATOR, $relpath.'/'.$subFolder );
98 98
 
99 99
 				if( is_dir( $path ) )
100 100
 				{
@@ -132,7 +132,7 @@  discard block
 block discarded – undo
132 132
 			{
133 133
 				$name = strtolower( $entry->getBaseName() );
134 134
 				$it = new \DirectoryIterator( $entry->getPathName() );
135
-				$pref = ( $prefix !== '' ? $prefix . '/' : '' ) . $name;
135
+				$pref = ( $prefix !== '' ? $prefix.'/' : '' ).$name;
136 136
 				$subList = self::createControllers( $it, $context, $aimeos, $pref );
137 137
 
138 138
 				$list = array_merge( $list, $subList );
Please login to merge, or discard this patch.
lib/mshoplib/setup/LocaleChangeSitesToTree.php 1 patch
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -87,8 +87,7 @@  discard block
 block discarded – undo
87 87
 				$migrate = true;
88 88
 				$this->execute( $stmt );
89 89
 				$this->status( 'added' );
90
-			}
91
-			else
90
+			} else
92 91
 			{
93 92
 				$this->status( 'OK' );
94 93
 			}
@@ -131,8 +130,7 @@  discard block
 block discarded – undo
131 130
 				$stmt->execute()->finish();
132 131
 
133 132
 				$this->status( 'done' );
134
-			}
135
-			else
133
+			} else
136 134
 			{
137 135
 				$this->status( 'OK' );
138 136
 			}
Please login to merge, or discard this patch.
lib/mshoplib/setup/MShopAddLocaleData.php 2 patches
Braces   +18 added lines, -6 removed lines patch added patch discarded remove patch
@@ -166,10 +166,14 @@  discard block
 block discarded – undo
166 166
 			$currencyItem->setLabel( $dataset['label'] );
167 167
 			$currencyItem->setStatus( $dataset['status'] );
168 168
 
169
-			try {
169
+			try
170
+			{
170 171
 				$currencyItemManager->saveItem( $currencyItem );
171 172
 				$num++;
172
-			} catch( \Exception $e ) {; } // if currency was already available
173
+			}
174
+			catch( \Exception $e )
175
+			{
176
+; } // if currency was already available
173 177
 		}
174 178
 
175 179
 		$this->status( $num > 0 ? $num . '/' . $total : 'OK' );
@@ -198,10 +202,14 @@  discard block
 block discarded – undo
198 202
 			$languageItem->setLabel( $dataset['label'] );
199 203
 			$languageItem->setStatus( $dataset['status'] );
200 204
 
201
-			try {
205
+			try
206
+			{
202 207
 				$languageItemManager->saveItem( $languageItem );
203 208
 				$num++;
204
-			} catch( \Exception $e ) {; } // if language was already available
209
+			}
210
+			catch( \Exception $e )
211
+			{
212
+; } // if language was already available
205 213
 		}
206 214
 
207 215
 		$this->status( $num > 0 ? $num . '/' . $total : 'OK' );
@@ -233,9 +241,13 @@  discard block
 block discarded – undo
233 241
 			$localeItem->setPosition( $dataset['pos'] );
234 242
 			$localeItem->setStatus( $dataset['status'] );
235 243
 
236
-			try {
244
+			try
245
+			{
237 246
 				$localeItemManager->saveItem( $localeItem );
238
-			} catch( \Exception $e ) {; } // if locale combination was already available
247
+			}
248
+			catch( \Exception $e )
249
+			{
250
+; } // if locale combination was already available
239 251
 		}
240 252
 
241 253
 		$this->status( 'done' );
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -179,7 +179,7 @@  discard block
 block discarded – undo
179 179
 			} catch( \Exception $e ) {; } // if currency was already available
180 180
 		}
181 181
 
182
-		$this->status( $num > 0 ? $num . '/' . $total : 'OK' );
182
+		$this->status( $num > 0 ? $num.'/'.$total : 'OK' );
183 183
 	}
184 184
 
185 185
 
@@ -211,7 +211,7 @@  discard block
 block discarded – undo
211 211
 			} catch( \Exception $e ) {; } // if language was already available
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.
lib/mshoplib/setup/MShopAddPluginData.php 2 patches
Braces   +6 added lines, -2 removed lines patch added patch discarded remove patch
@@ -115,10 +115,14 @@
 block discarded – undo
115 115
 				$item->setPosition( $dataset['position'] );
116 116
 			}
117 117
 
118
-			try {
118
+			try
119
+			{
119 120
 				$pluginManager->saveItem( $item );
120 121
 				$num++;
121
-			} catch( \Exception $e ) {; } // if plugin configuration was already available
122
+			}
123
+			catch( \Exception $e )
124
+			{
125
+; } // if plugin configuration was already available
122 126
 		}
123 127
 
124 128
 		$this->status( $num > 0 ? $num . '/' . $total : 'OK' );
Please login to merge, or discard this patch.
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -64,7 +64,7 @@  discard block
 block discarded – undo
64 64
 		$pluginManager = \Aimeos\MShop\Plugin\Manager\Factory::createManager( $this->additional, 'Standard' );
65 65
 
66 66
 
67
-		$filename = __DIR__ . $ds . 'default' . $ds . 'data' . $ds . 'plugin.php';
67
+		$filename = __DIR__.$ds.'default'.$ds.'data'.$ds.'plugin.php';
68 68
 
69 69
 		if( ( $data = include( $filename ) ) == false ) {
70 70
 			throw new \Aimeos\MW\Setup\Exception( sprintf( 'No data file "%1$s" found', $filename ) );
@@ -90,7 +90,7 @@  discard block
 block discarded – undo
90 90
 		$manager = $pluginManager->getSubManager( 'type' );
91 91
 
92 92
 		foreach( $manager->searchItems( $manager->createSearch() ) as $item ) {
93
-			$types['plugin/' . $item->getCode()] = $item;
93
+			$types['plugin/'.$item->getCode()] = $item;
94 94
 		}
95 95
 
96 96
 		$num = $total = 0;
@@ -121,6 +121,6 @@  discard block
 block discarded – undo
121 121
 			} catch( \Exception $e ) {; } // if plugin configuration was already available
122 122
 		}
123 123
 
124
-		$this->status( $num > 0 ? $num . '/' . $total : 'OK' );
124
+		$this->status( $num > 0 ? $num.'/'.$total : 'OK' );
125 125
 	}
126 126
 }
127 127
\ No newline at end of file
Please login to merge, or discard this patch.
lib/mshoplib/setup/TablesAddLogColumns.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -779,8 +779,7 @@
 block discarded – undo
779 779
 					{
780 780
 						$this->executeList( $stmtList );
781 781
 						$this->status( 'added' );
782
-					}
783
-					else
782
+					} else
784 783
 					{
785 784
 						$this->status( 'OK' );
786 785
 					}
Please login to merge, or discard this patch.
lib/mshoplib/setup/default/DemoAddCatalogData.php 2 patches
Braces   +4 added lines, -3 removed lines patch added patch discarded remove patch
@@ -66,7 +66,9 @@  discard block
 block discarded – undo
66 66
 			$this->removeItems( $item->getId(), 'catalog/lists', 'catalog', 'text' );
67 67
 			$this->removeListItems( $item->getId(), 'catalog/lists', 'product' );
68 68
 		}
69
-		catch( \Exception $e ) {; } // If no root node was already inserted into the database
69
+		catch( \Exception $e )
70
+		{
71
+; } // If no root node was already inserted into the database
70 72
 
71 73
 
72 74
 		if( $context->getConfig()->get( 'setup/default/demo', false ) == true )
@@ -103,8 +105,7 @@  discard block
 block discarded – undo
103 105
 			}
104 106
 
105 107
 			$this->status( 'added' );
106
-		}
107
-		else
108
+		} else
108 109
 		{
109 110
 			$this->status( 'removed' );
110 111
 		}
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -81,7 +81,7 @@
 block discarded – undo
81 81
 		if( $value === '1' )
82 82
 		{
83 83
 			$ds = DIRECTORY_SEPARATOR;
84
-			$path = __DIR__ . $ds . 'data' . $ds . 'demo-catalog.php';
84
+			$path = __DIR__.$ds.'data'.$ds.'demo-catalog.php';
85 85
 
86 86
 			if( ( $data = include( $path ) ) == false ) {
87 87
 				throw new \Aimeos\MShop\Exception( sprintf( 'No file "%1$s" found for catalog domain', $path ) );
Please login to merge, or discard this patch.
lib/mshoplib/setup/unittest/data/supplier-list.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -5,12 +5,12 @@
 block discarded – undo
5 5
  * @copyright Aimeos (aimeos.org), 2015
6 6
  */
7 7
 
8
-return array (
9
-	'supplier/lists/type' => array (
8
+return array(
9
+	'supplier/lists/type' => array(
10 10
 		'text/default' => array( 'domain' => 'text', 'code' => 'default', 'label' => 'Standard', 'status' => 1 ),
11 11
 	),
12 12
 
13
-	'supplier/lists' => array (
13
+	'supplier/lists' => array(
14 14
 		array( 'parentid' => 'supplier/unitCode001', 'typeid' => 'text/default', 'domain' => 'text', 'refid' => 'text/supplier/description', 'start' => '2010-01-01 00:00:00', 'end' => '2100-01-01 00:00:00', 'config' => array(), 'pos' => 0, 'status' => 1 ),
15 15
 		array( 'parentid' => 'supplier/unitCode001', 'typeid' => 'text/default', 'domain' => 'text', 'refid' => 'text/customer/notify', 'start' => '2010-01-01 00:00:00', 'end' => '2022-01-01 00:00:00', 'config' => array(), 'pos' => 1, 'status' => 1 ),
16 16
 		array( 'parentid' => 'supplier/unitCode001', 'typeid' => 'text/default', 'domain' => 'text', 'refid' => 'text/customer/newsletter', 'start' => '2010-01-01 00:00:00', 'end' => '2022-01-01 00:00:00', 'config' => array(), 'pos' => 2, 'status' => 1 ),
Please login to merge, or discard this patch.