Completed
Push — 2.0-dev ( 9a136b...785deb )
by Michael
13:54 queued 06:40
created
src/Client.php 1 patch
Braces   +7 added lines, -14 removed lines patch added patch discarded remove patch
@@ -121,8 +121,7 @@  discard block
 block discarded – undo
121 121
 		if (strcmp($this->version, '1.0a') === 0)
122 122
 		{
123 123
 			$verifier = $this->input->get('oauth_verifier');
124
-		}
125
-		else
124
+		} else
126 125
 		{
127 126
 			$verifier = $this->input->get('oauth_token');
128 127
 		}
@@ -282,8 +281,7 @@  discard block
 block discarded – undo
282 281
 		if (isset($headers['Content-Type']) && strpos($headers['Content-Type'], 'multipart/form-data') !== false || !is_array($data))
283 282
 		{
284 283
 			$oauth_headers = $parameters;
285
-		}
286
-		else
284
+		} else
287 285
 		{
288 286
 			// Use all parameters for the signature.
289 287
 			$oauth_headers = array_merge($parameters, $data);
@@ -355,8 +353,7 @@  discard block
 block discarded – undo
355 353
 			if (!strcmp($header, 'OAuth '))
356 354
 			{
357 355
 				$header .= $key . '="' . $this->safeEncode($value) . '"';
358
-			}
359
-			else
356
+			} else
360 357
 			{
361 358
 				$header .= ', ' . $key . '="' . $value . '"';
362 359
 			}
@@ -386,16 +383,14 @@  discard block
 block discarded – undo
386 383
 					if (strpos($url, '?') === false)
387 384
 					{
388 385
 						$url .= '?';
389
-					}
390
-					else
386
+					} else
391 387
 					{
392 388
 						$url .= '&';
393 389
 					}
394 390
 
395 391
 					$url .= $key . '=' . $v;
396 392
 				}
397
-			}
398
-			else
393
+			} else
399 394
 			{
400 395
 				if (strpos($value, ' ') !== false)
401 396
 				{
@@ -405,8 +400,7 @@  discard block
 block discarded – undo
405 400
 				if (strpos($url, '?') === false)
406 401
 				{
407 402
 					$url .= '?';
408
-				}
409
-				else
403
+				} else
410 404
 				{
411 405
 					$url .= '&';
412 406
 				}
@@ -471,8 +465,7 @@  discard block
 block discarded – undo
471 465
 					$v    = $this->safeEncode($v);
472 466
 					$kv[] = "{$key}={$v}";
473 467
 				}
474
-			}
475
-			else
468
+			} else
476 469
 			{
477 470
 				$value = $this->safeEncode($value);
478 471
 				$kv[]  = "{$key}={$value}";
Please login to merge, or discard this patch.
Tests/ClientTest.php 1 patch
Braces   +4 added lines, -8 removed lines patch added patch discarded remove patch
@@ -142,8 +142,7 @@  discard block
 block discarded – undo
142 142
 			$this->object->setToken($token);
143 143
 			$result = $this->object->authenticate();
144 144
 			$this->assertEquals($result, $token);
145
-		}
146
-		else
145
+		} else
147 146
 		{
148 147
 			$this->object->setOption('requestTokenURL', 'https://example.com/request_token');
149 148
 			$this->object->setOption('authoriseURL', 'https://example.com/authorize');
@@ -181,8 +180,7 @@  discard block
 block discarded – undo
181 180
 			{
182 181
 				TestHelper::setValue($this->object, 'version', $version);
183 182
 				$data = array('oauth_verifier' => 'verifier', 'oauth_token' => 'token');
184
-			}
185
-			else
183
+			} else
186 184
 			{
187 185
 				TestHelper::setValue($this->object, 'version', $version);
188 186
 				$data = array('oauth_token' => 'token');
@@ -211,8 +209,7 @@  discard block
 block discarded – undo
211 209
 				if (method_exists($this, 'expectException'))
212 210
 				{
213 211
 					$this->expectException('DomainException');
214
-				}
215
-				else
212
+				} else
216 213
 				{
217 214
 					$this->setExpectedException('DomainException');
218 215
 				}
@@ -315,8 +312,7 @@  discard block
 block discarded – undo
315 312
 					array('Content-Type' => 'multipart/form-data')
316 313
 				)
317 314
 			);
318
-		}
319
-		else
315
+		} else
320 316
 		{
321 317
 			$this->client->expects($this->at(0))
322 318
 				->method($method)
Please login to merge, or discard this patch.