Issues (19)

src/Exceptions/AmazonErrors.php (1 issue)

Labels
Severity
1
<?php
2
3
/**
4
 * Part of the AmazonGiftCode package.
5
 * Author: Kashyap Merai <[email protected]>
6
 *
7
 */
8
9
10
namespace kamerk22\AmazonGiftCode\Exceptions;
11
12
13
use RuntimeException;
14
15
class AmazonErrors extends RuntimeException
16
{
17
    /**
18
     * @param string $message
19
     * @param string $_error_code
20
     * @return AmazonErrors
21
     */
22
    public static function getError(string $message, string $_error_code): self
23
    {
24
        return new static($message, $_error_code);
0 ignored issues
show
$_error_code of type string is incompatible with the type integer expected by parameter $code of kamerk22\AmazonGiftCode\...onErrors::__construct(). ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-type  annotation

24
        return new static($message, /** @scrutinizer ignore-type */ $_error_code);
Loading history...
25
    }
26
27
}