mirror of
https://tt-rss.org/git/tt-rss.git
synced 2024-07-07 13:40:53 +02:00
16 lines
317 B
PHP
16 lines
317 B
PHP
<?php
|
|
|
|
|
|
namespace Safe\Exceptions;
|
|
|
|
class CurlException extends \Exception implements SafeExceptionInterface
|
|
{
|
|
/**
|
|
* @param \CurlHandle $ch
|
|
*/
|
|
public static function createFromPhpError($ch = null): self
|
|
{
|
|
return new self($ch ? \curl_error($ch) : '', $ch ? \curl_errno($ch) : 0);
|
|
}
|
|
}
|