Issues (13)

src/Exceptions/UploadException.php (1 issue)

Labels
Severity
1
<?php
2
3
namespace Owowagency\LaravelMedia\Exceptions;
4
5
use Exception;
6
7
class UploadException extends Exception
8
{
9
    /**
10
     * UploadException constructor.
11
     *
12
     * @param  string  $type
13
     */
14
    public function __construct(string $type = 'string')
15
    {
16
        $message = trans('laravel-media::general.exception', [
17
            'type' => $type,
18
        ]);
19
20
        parent::__construct($message, 0, null);
0 ignored issues
show
It seems like $message can also be of type array and array; however, parameter $message of Exception::__construct() does only seem to accept string, maybe add an additional type check? ( Ignorable by Annotation )

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

20
        parent::__construct(/** @scrutinizer ignore-type */ $message, 0, null);
Loading history...
21
    }
22
}
23