Passed
Push — master ( f7bbd3...17cd43 )
by Aimeos
04:27
created
lib/mwlib/src/MW/DB/Statement/PDO/Simple.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -56,7 +56,7 @@
 block discarded – undo
56 56
 			case \Aimeos\MW\DB\Statement\Base::PARAM_NULL:
57 57
 				$this->binds[$position] = 'NULL'; break;
58 58
 			case \Aimeos\MW\DB\Statement\Base::PARAM_BOOL:
59
-				$this->binds[$position] = ((bool) $value ? 'TRUE' : 'FALSE'); break;
59
+				$this->binds[$position] = ( (bool) $value ? 'TRUE' : 'FALSE' ); break;
60 60
 			case \Aimeos\MW\DB\Statement\Base::PARAM_INT:
61 61
 				$this->binds[$position] = (int) $value; break;
62 62
 			case \Aimeos\MW\DB\Statement\Base::PARAM_FLOAT:
Please login to merge, or discard this patch.
Braces   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -86,9 +86,12 @@
 block discarded – undo
86 86
 			throw new \Aimeos\MW\DB\Exception( sprintf( $msg, count( $this->binds ), implode( '?', $this->parts ) ) );
87 87
 		}
88 88
 
89
-		try {
89
+		try
90
+		{
90 91
 			$result = $this->exec();
91
-		} catch( \PDOException $e ) {
92
+		}
93
+		catch( \PDOException $e )
94
+		{
92 95
 			throw new \Aimeos\MW\DB\Exception( $e->getMessage(), $e->getCode() );
93 96
 		}
94 97
 
Please login to merge, or discard this patch.
lib/mshoplib/setup/default/schema/customer.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -8,7 +8,7 @@  discard block
 block discarded – undo
8 8
 
9 9
 return array(
10 10
 	'table' => array(
11
-		'mshop_customer' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
11
+		'mshop_customer' => function( \Doctrine\DBAL\Schema\Schema $schema ) {
12 12
 
13 13
 			$table = $schema->createTable( 'mshop_customer' );
14 14
 
@@ -42,7 +42,7 @@  discard block
 block discarded – undo
42 42
 			$table->addColumn( 'status', 'smallint', [] );
43 43
 			$table->addColumn( 'mtime', 'datetime', [] );
44 44
 			$table->addColumn( 'ctime', 'datetime', [] );
45
-			$table->addColumn( 'editor', 'string', array('length' => 255 ) );
45
+			$table->addColumn( 'editor', 'string', array( 'length' => 255 ) );
46 46
 
47 47
 			$table->setPrimaryKey( array( 'id' ), 'pk_mscus_id' );
48 48
 			$table->addUniqueIndex( array( 'siteid', 'code' ), 'unq_mscus_sid_code' );
@@ -56,7 +56,7 @@  discard block
 block discarded – undo
56 56
 			return $schema;
57 57
 		},
58 58
 
59
-		'mshop_customer_address' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
59
+		'mshop_customer_address' => function( \Doctrine\DBAL\Schema\Schema $schema ) {
60 60
 
61 61
 			$table = $schema->createTable( 'mshop_customer_address' );
62 62
 
@@ -87,7 +87,7 @@  discard block
 block discarded – undo
87 87
 			$table->addColumn( 'pos', 'smallint', [] );
88 88
 			$table->addColumn( 'mtime', 'datetime', [] );
89 89
 			$table->addColumn( 'ctime', 'datetime', [] );
90
-			$table->addColumn( 'editor', 'string', array('length' => 255 ) );
90
+			$table->addColumn( 'editor', 'string', array( 'length' => 255 ) );
91 91
 
92 92
 			$table->setPrimaryKey( array( 'id' ), 'pk_mscusad_id' );
93 93
 			$table->addIndex( array( 'parentid' ), 'fk_mscusad_pid' );
@@ -104,7 +104,7 @@  discard block
 block discarded – undo
104 104
 			return $schema;
105 105
 		},
106 106
 
107
-		'mshop_customer_list_type' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
107
+		'mshop_customer_list_type' => function( \Doctrine\DBAL\Schema\Schema $schema ) {
108 108
 
109 109
 			$table = $schema->createTable( 'mshop_customer_list_type' );
110 110
 
@@ -127,7 +127,7 @@  discard block
 block discarded – undo
127 127
 			return $schema;
128 128
 		},
129 129
 
130
-		'mshop_customer_list' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
130
+		'mshop_customer_list' => function( \Doctrine\DBAL\Schema\Schema $schema ) {
131 131
 
132 132
 			$table = $schema->createTable( 'mshop_customer_list' );
133 133
 
@@ -165,7 +165,7 @@  discard block
 block discarded – undo
165 165
 			return $schema;
166 166
 		},
167 167
 
168
-		'mshop_customer_group' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
168
+		'mshop_customer_group' => function( \Doctrine\DBAL\Schema\Schema $schema ) {
169 169
 
170 170
 			$table = $schema->createTable( 'mshop_customer_group' );
171 171
 
@@ -184,7 +184,7 @@  discard block
 block discarded – undo
184 184
 			return $schema;
185 185
 		},
186 186
 
187
-		'mshop_customer_property_type' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
187
+		'mshop_customer_property_type' => function( \Doctrine\DBAL\Schema\Schema $schema ) {
188 188
 
189 189
 			$table = $schema->createTable( 'mshop_customer_property_type' );
190 190
 
@@ -207,7 +207,7 @@  discard block
 block discarded – undo
207 207
 			return $schema;
208 208
 		},
209 209
 
210
-		'mshop_customer_property' => function ( \Doctrine\DBAL\Schema\Schema $schema ) {
210
+		'mshop_customer_property' => function( \Doctrine\DBAL\Schema\Schema $schema ) {
211 211
 
212 212
 			$table = $schema->createTable( 'mshop_customer_property' );
213 213
 
Please login to merge, or discard this patch.
lib/mshoplib/setup/ServiceUniqueCode.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -76,8 +76,7 @@
 block discarded – undo
76 76
 			$this->release( $conn );
77 77
 
78 78
 			$this->status( 'done' );
79
-		}
80
-		else
79
+		} else
81 80
 		{
82 81
 			$this->status( 'OK' );
83 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
@@ -59,9 +59,12 @@
 block discarded – undo
59 59
 	 */
60 60
 	public function execute()
61 61
 	{
62
-		try {
62
+		try
63
+		{
63 64
 			$stmt = $this->exec();
64
-		} catch( \PDOException $e ) {
65
+		}
66
+		catch( \PDOException $e )
67
+		{
65 68
 			throw new \Aimeos\MW\DB\Exception( $e->getMessage(), $e->getCode(), $e->errorInfo );
66 69
 		}
67 70
 
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
@@ -58,9 +58,12 @@
 block discarded – undo
58 58
 	 */
59 59
 	public function execute()
60 60
 	{
61
-		try {
61
+		try
62
+		{
62 63
 			$stmt = $this->exec();
63
-		} catch( \PDOException $e ) {
64
+		}
65
+		catch( \PDOException $e )
66
+		{
64 67
 			throw new \Aimeos\MW\DB\Exception( $e->getMessage(), $e->getCode() );
65 68
 		}
66 69
 
Please login to merge, or discard this patch.
lib/mwlib/src/MW/Common/Manager/Base.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -69,9 +69,9 @@  discard block
 block discarded – undo
69 69
 		foreach( $attributes as $key => $item )
70 70
 		{
71 71
 			if( $item instanceof $iface ) {
72
-				$list[ $item->getCode() ] = $item->getFunction();
72
+				$list[$item->getCode()] = $item->getFunction();
73 73
 			} else if( isset( $item['code'] ) ) {
74
-				$list[ $item['code'] ] = $item['function'];
74
+				$list[$item['code']] = $item['function'];
75 75
 			} else {
76 76
 				throw new \Aimeos\MW\Common\Exception( sprintf( 'Invalid attribute at position "%1$d"', $key ) );
77 77
 			}
@@ -97,9 +97,9 @@  discard block
 block discarded – undo
97 97
 		foreach( $attributes as $key => $item )
98 98
 		{
99 99
 			if( $item instanceof $iface ) {
100
-				$translations[ $item->getCode() ] = $item->getInternalCode();
100
+				$translations[$item->getCode()] = $item->getInternalCode();
101 101
 			} else if( isset( $item['code'] ) ) {
102
-				$translations[ $item['code'] ] = $item['internalcode'];
102
+				$translations[$item['code']] = $item['internalcode'];
103 103
 			} else {
104 104
 				throw new \Aimeos\MW\Common\Exception( sprintf( 'Invalid attribute at position "%1$d"', $key ) );
105 105
 			}
@@ -125,9 +125,9 @@  discard block
 block discarded – undo
125 125
 		foreach( $attributes as $key => $item )
126 126
 		{
127 127
 			if( $item instanceof $iface ) {
128
-				$types[ $item->getCode() ] = $item->getInternalType();
128
+				$types[$item->getCode()] = $item->getInternalType();
129 129
 			} else if( isset( $item['code'] ) ) {
130
-				$types[ $item['code'] ] = $item['internaltype'];
130
+				$types[$item['code']] = $item['internaltype'];
131 131
 			} else {
132 132
 				throw new \Aimeos\MW\Common\Exception( sprintf( 'Invalid attribute at position "%1$d"', $key ) );
133 133
 			}
Please login to merge, or discard this patch.
lib/mwlib/tests/MW/Criteria/Attribute/StandardTest.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -32,7 +32,7 @@  discard block
 block discarded – undo
32 32
 			'function' => $func,
33 33
 		);
34 34
 
35
-		$this->object = new \Aimeos\MW\Criteria\Attribute\Standard($values);
35
+		$this->object = new \Aimeos\MW\Criteria\Attribute\Standard( $values );
36 36
 	}
37 37
 
38 38
 
@@ -68,7 +68,7 @@  discard block
 block discarded – undo
68 68
 
69 69
 	public function testGetInternalDeps()
70 70
 	{
71
-		$this->assertEquals(array( 'test' ), $this->object->getInternalDeps());
71
+		$this->assertEquals( array( 'test' ), $this->object->getInternalDeps() );
72 72
 	}
73 73
 
74 74
 
Please login to merge, or discard this patch.
lib/mshoplib/src/MShop/Locale/Manager/Standard.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -317,8 +317,7 @@
 block discarded – undo
317 317
 				 * @see mshop/locale/manager/standard/count/ansi
318 318
 				 */
319 319
 				$path = 'mshop/locale/manager/standard/insert';
320
-			}
321
-			else
320
+			} else
322 321
 			{
323 322
 				/** mshop/locale/manager/standard/update/mysql
324 323
 				 * Updates an existing locale record in the database
Please login to merge, or discard this patch.
lib/mshoplib/setup/unittest/data/media-property.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -5,7 +5,7 @@
 block discarded – undo
5 5
  * @copyright Aimeos (aimeos.org), 2017-2018
6 6
  */
7 7
 
8
-return array (
8
+return array(
9 9
 	'media/property/type' => array(
10 10
 		'media/property/type/size' => array( 'domain' => 'media', 'code' => 'size', 'label' => 'Size', 'status' => 1 ),
11 11
 		'media/property/type/mtime' => array( 'domain' => 'media', 'code' => 'mtime', 'label' => 'Modification time', 'status' => 1 ),
Please login to merge, or discard this patch.