$statement->errorInfo() of type array is incompatible with the type string expected by parameter $message of Exception::__construct().
(
Ignorable by Annotation
)
If this is a false-positive, you can also ignore this issue in your code via the ignore-type annotation
79
throw new Exception(/** @scrutinizer ignore-type */ $statement->errorInfo());
This check looks for assignments to scalar types that may be of the wrong type.
To ensure the code behaves as expected, it may be a good idea to add an explicit type cast.