mirror of
https://github.com/friendica/friendica
synced 2025-04-30 07:04:23 +02:00
Catch all errors thrown by "fetchRaw"
This commit is contained in:
parent
6870ccc00e
commit
2b513a48c7
8 changed files with 64 additions and 28 deletions
|
@ -422,7 +422,12 @@ class HTTPSignature
|
|||
*/
|
||||
public static function fetch(string $request, int $uid): array
|
||||
{
|
||||
$curlResult = self::fetchRaw($request, $uid);
|
||||
try {
|
||||
$curlResult = self::fetchRaw($request, $uid);
|
||||
} catch (\Throwable $th) {
|
||||
Logger::notice('Error fetching url', ['url' => $request, 'error' => $th]);
|
||||
return [];
|
||||
}
|
||||
|
||||
if (empty($curlResult)) {
|
||||
return [];
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue