|
@@ -211,7 +211,7 @@ discard block |
|
|
block discarded – undo |
|
211
|
211
|
]; |
|
212
|
212
|
|
|
213
|
213
|
if ($domain = $this->getDomain()) { |
|
214
|
|
- $data['domain'] = $domain; |
|
|
214
|
+ $data[ 'domain' ] = $domain; |
|
215
|
215
|
} |
|
216
|
216
|
|
|
217
|
217
|
$response = $client->post('shorten', [ |
|
@@ -220,10 +220,10 @@ discard block |
|
|
block discarded – undo |
|
220
|
220
|
|
|
221
|
221
|
$responseData = json_decode($response->getBody(), true); |
|
222
|
222
|
if ($response->getStatusCode() != 200 && $response->getStatusCode() != 201) { |
|
223
|
|
- throw new \Exception($responseData['message'] . ' : ' . $responseData['description']); |
|
|
223
|
+ throw new \Exception($responseData[ 'message' ] . ' : ' . $responseData[ 'description' ]); |
|
224
|
224
|
} |
|
225
|
225
|
|
|
226
|
|
- $this->ShortURL = $responseData['link']; |
|
|
226
|
+ $this->ShortURL = $responseData[ 'link' ]; |
|
227
|
227
|
} |
|
228
|
228
|
|
|
229
|
229
|
parent::onBeforeWrite(); |
Please login to merge, or discard this patch.