mirror of
https://codeberg.org/demostf/api.git
synced 2026-06-03 18:04:08 +02:00
add phan
This commit is contained in:
parent
6adcdc2362
commit
b3fbc1be3c
7 changed files with 91 additions and 10 deletions
|
|
@ -5,7 +5,7 @@ declare(strict_types=1);
|
|||
namespace Demostf\API\Demo;
|
||||
|
||||
use GuzzleHttp\Client;
|
||||
use GuzzleHttp\Exception\GuzzleException;
|
||||
use GuzzleHttp\Exception\RequestException;
|
||||
|
||||
/**
|
||||
* Wrapper around demo.js parser.
|
||||
|
|
@ -32,7 +32,7 @@ class RawParser {
|
|||
} else {
|
||||
return $result;
|
||||
}
|
||||
} catch (GuzzleException $e) {
|
||||
} catch (RequestException $e) {
|
||||
if (strpos($e->getMessage(), 'cURL error 52') !== false) {
|
||||
throw new \Exception('Failed to parse demo, can\'t reach demo parser');
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue