Better error handling in case of place creation failure

This commit is contained in:
Jonny Barnes 2016-09-22 16:00:04 +01:00
parent 0a9aafb620
commit 32af94fab8
2 changed files with 6 additions and 2 deletions

View file

@ -263,7 +263,7 @@ class MicropubClientController extends Controller
'headers' => $headers,
]);
} catch (ClientException $e) {
//not sure yet...
return false;
}
if ($response->getStatusCode() == 201) {
return $response->getHeader('Location')[0];