summaryrefslogtreecommitdiff
path: root/vendor/thecodingmachine/safe/lib/Exceptions/JsonException.php
blob: 4300d29e9ec10b8fba840456d2299b1e624b5596 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
<?php


namespace Safe\Exceptions;

class JsonException extends \Exception implements SafeExceptionInterface
{
    public static function createFromPhpError(): self
    {
        return new self(\json_last_error_msg(), \json_last_error());
    }
}