Completed
Push — master ( fc07f9...c011fc )
by Milan
01:50
created
src/Request/Queue.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -66,7 +66,7 @@  discard block
 block discarded – undo
66 66
 	 */
67 67
 	public function download($token, $url)
68 68
 	{
69
-		$response = $this->request($token, function (GuzzleHttp\Client $client) use ($url) {
69
+		$response = $this->request($token, function(GuzzleHttp\Client $client) use ($url) {
70 70
 			return $client->request('GET', $url, $this->downloadOptions);
71 71
 		});
72 72
 		self::detectDownloadResponse($response);
@@ -85,7 +85,7 @@  discard block
 block discarded – undo
85 85
 		}
86 86
 		$newPost[] = ['name' => 'file', 'contents' => fopen($filename, 'r')];
87 87
 
88
-		$response = $this->request($token, function (GuzzleHttp\Client $client) use ($url, $newPost) {
88
+		$response = $this->request($token, function(GuzzleHttp\Client $client) use ($url, $newPost) {
89 89
 			return $client->request('POST', $url, [GuzzleHttp\RequestOptions::MULTIPART => $newPost]);
90 90
 		});
91 91
 		return self::createXmlResponse($response->getBody());
@@ -116,12 +116,12 @@  discard block
 block discarded – undo
116 116
 					throw $e;
117 117
 				} elseif ($i >= $this->limitLoop) {
118 118
 					fclose($file);
119
-					throw new Fio\QueueLimitException('You have limit up requests to server ' . $this->limitLoop);
119
+					throw new Fio\QueueLimitException('You have limit up requests to server '.$this->limitLoop);
120 120
 				}
121 121
 				self::sleep($tempFile);
122 122
 				$next = true;
123 123
 			} catch (GuzzleHttp\Exception\ServerException $e) {
124
-				if($e->hasResponse()) {
124
+				if ($e->hasResponse()) {
125 125
 					self::detectDownloadResponse($e->getResponse());
126 126
 				}
127 127
 				throw self::createServiceUnavailableException();
@@ -168,7 +168,7 @@  discard block
 block discarded – undo
168 168
 	{
169 169
 		$key = substr($token, 10, -10);
170 170
 		if (!isset(self::$tokens[$key])) {
171
-			self::$tokens[$key] = $this->tempDir . DIRECTORY_SEPARATOR . md5($key);
171
+			self::$tokens[$key] = $this->tempDir.DIRECTORY_SEPARATOR.md5($key);
172 172
 		}
173 173
 
174 174
 		return self::$tokens[$key];
@@ -176,7 +176,7 @@  discard block
 block discarded – undo
176 176
 
177 177
 	private static function safeProtocol($filename)
178 178
 	{
179
-		return Utils\SafeStream::PROTOCOL . '://' . $filename;
179
+		return Utils\SafeStream::PROTOCOL.'://'.$filename;
180 180
 	}
181 181
 
182 182
 	/**
Please login to merge, or discard this patch.