Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DisallowedShortTernaryOperator suppress doesnt work #656

Open
keizah7 opened this issue Aug 17, 2023 · 0 comments
Open

DisallowedShortTernaryOperator suppress doesnt work #656

keizah7 opened this issue Aug 17, 2023 · 0 comments

Comments

@keizah7
Copy link

keizah7 commented Aug 17, 2023

Q A
Bug report? yes
Feature request? no
Library version 2.8

DisallowedShortTernaryOperator suppress doesnt work

class RedirectIfAuthenticated
{
    /**
     * Handle an incoming request.
     *
     * @phpcsSuppress DisallowedShortTernaryOperator
     */
    public function handle(Request $request, Closure $next, string ...$guards)
    {
        $guards = $guards ?: ['web'];
• [Code] Disallow short ternary operator: (SlevomatCodingStandard\Sniffs\ControlStructures\DisallowShortTernaryOperatorSniff)
  app/Http/Middleware/RedirectIfAuthenticated.php:21: Use of short ternary operator is disallowed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant