Completed
Push — 2.0-dev ( 12bc3d...96d101 )
by Michael
06:20
created
Tests/ClientTest.php 2 patches
Braces   +3 added lines, -6 removed lines patch added patch discarded remove patch
@@ -136,8 +136,7 @@  discard block
 block discarded – undo
136 136
 			$this->object->setToken($token);
137 137
 			$result = $this->object->authenticate();
138 138
 			$this->assertEquals($result, $token);
139
-		}
140
-		else
139
+		} else
141 140
 		{
142 141
 			$this->object->setOption('requestTokenURL', 'https://example.com/request_token');
143 142
 			$this->object->setOption('authoriseURL', 'https://example.com/authorize');
@@ -175,8 +174,7 @@  discard block
 block discarded – undo
175 174
 			{
176 175
 				TestHelper::setValue($this->object, 'version', $version);
177 176
 				$data = array('oauth_verifier' => 'verifier', 'oauth_token' => 'token');
178
-			}
179
-			else
177
+			} else
180 178
 			{
181 179
 				TestHelper::setValue($this->object, 'version', $version);
182 180
 				$data = array('oauth_token' => 'token');
@@ -302,8 +300,7 @@  discard block
 block discarded – undo
302 300
 				$this->object->oauthRequest('www.example.com', $method, array('oauth_token' => '1235'), $data, array('Content-Type' => 'multipart/form-data')),
303 301
 				$this->equalTo($returnData)
304 302
 				);
305
-		}
306
-		else
303
+		} else
307 304
 		{
308 305
 			$this->client->expects($this->at(0))
309 306
 				->method($method)
Please login to merge, or discard this patch.
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -260,10 +260,10 @@
 block discarded – undo
260 260
 	}
261 261
 
262 262
 	/**
263
-	* Provides test data.
264
-	*
265
-	* @return  array
266
-	*/
263
+	 * Provides test data.
264
+	 *
265
+	 * @return  array
266
+	 */
267 267
 	public function seedOauthRequest()
268 268
 	{
269 269
 		// Method
Please login to merge, or discard this patch.
src/Client.php 2 patches
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -1,10 +1,10 @@
 block discarded – undo
1 1
 <?php
2 2
 /**
3
- * Part of the Joomla Framework OAuth1 Package
4
- *
5
- * @copyright  Copyright (C) 2005 - 2015 Open Source Matters, Inc. All rights reserved.
6
- * @license    GNU General Public License version 2 or later; see LICENSE
7
- */
3
+	 * Part of the Joomla Framework OAuth1 Package
4
+	 *
5
+	 * @copyright  Copyright (C) 2005 - 2015 Open Source Matters, Inc. All rights reserved.
6
+	 * @license    GNU General Public License version 2 or later; see LICENSE
7
+	 */
8 8
 
9 9
 namespace Joomla\Oauth1;
10 10
 
Please login to merge, or discard this 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/Stub/TestClient.php 1 patch
Indentation   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -1,8 +1,8 @@
 block discarded – undo
1 1
 <?php
2 2
 /**
3
- * @copyright  Copyright (C) 2005 - 2015 Open Source Matters, Inc. All rights reserved.
4
- * @license    GNU General Public License version 2 or later; see LICENSE
5
- */
3
+	 * @copyright  Copyright (C) 2005 - 2015 Open Source Matters, Inc. All rights reserved.
4
+	 * @license    GNU General Public License version 2 or later; see LICENSE
5
+	 */
6 6
 
7 7
 namespace Joomla\OAuth1\Tests;
8 8
 
Please login to merge, or discard this patch.