get csrf once,avoid init csrfMiddleware from view injection #640
Annotations
11 errors
|
Static analysis.:
src/CsrfViewInjection.php#L14
src/CsrfViewInjection.php:14:42: UndefinedClass: Class, interface or enum named Yiisoft\Yii\View\Renderer\CsrfParametersInjectionInterface does not exist (see https://psalm.dev/019)
|
Static analysis.:
src/ViewRenderer.php#L115
src/ViewRenderer.php:115:71: InvalidArrayOffset: Cannot access value on variable $csrfParameters using offset value of '0', expecting string (see https://psalm.dev/115)
|
Static analysis.:
src/ViewRenderer.php#L115
src/ViewRenderer.php:115:71: MixedArgument: Argument 2 of array_merge cannot be mixed, expecting array<array-key, mixed> (see https://psalm.dev/030)
|
Static analysis.:
src/ViewRenderer.php#L117
src/ViewRenderer.php:117:55: InvalidArrayOffset: Cannot access value on variable $csrfParameters using offset value of '1', expecting string (see https://psalm.dev/115)
|
Static analysis.:
src/ViewRenderer.php#L117
src/ViewRenderer.php:117:55: MixedArgument: Argument 2 of array_merge cannot be mixed, expecting array<array-key, mixed> (see https://psalm.dev/030)
|
Static analysis.:
src/ViewRenderer.php#L123
src/ViewRenderer.php:123:13: MixedArgumentTypeCoercion: Argument 3 of Yiisoft\Yii\View\Renderer\ViewRenderer::renderProxy expects array<string, mixed>, but parent type array<array-key, mixed> provided (see https://psalm.dev/194)
|
Static analysis.:
src/ViewRenderer.php#L356
src/ViewRenderer.php:356:22: MixedReturnTypeCoercion: The declared return type 'array<string, mixed>' for Yiisoft\Yii\View\Renderer\ViewRenderer::getCsrfParameters is more specific than the inferred return type 'array<array-key, mixed>' (see https://psalm.dev/197)
|
Static analysis.:
src/ViewRenderer.php#L361
src/ViewRenderer.php:361:54: UndefinedClass: Class, interface or enum named Yiisoft\Yii\View\Renderer\CsrfParametersInjectionInterface does not exist (see https://psalm.dev/019)
|
Static analysis.:
src/ViewRenderer.php#L361
src/ViewRenderer.php:361:54: MixedArgument: Argument 2 of Yiisoft\Yii\View\Renderer\ViewRenderer::getInjections cannot be mixed, expecting class-string (see https://psalm.dev/030)
|
Static analysis.:
src/ViewRenderer.php#L362
src/ViewRenderer.php:362:41: MixedMethodCall: Cannot determine the type of $injection when calling method getCsrfParameters (see https://psalm.dev/015)
|
Loading