Skip to content

Commit

Permalink
style(php-cs-fixer): fix code style and lint
Browse files Browse the repository at this point in the history
  • Loading branch information
remarkablemark authored and github-actions[bot] committed Dec 23, 2023
1 parent 1b1676c commit d1810ba
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/LaravelDatabaseExpressionsRector.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,9 @@ public function refactor(Node $node): ?Node

if (
// skip `DB::table()->select()`
($node instanceof MethodCall && $methodName === 'select')
($node instanceof MethodCall && 'select' === $methodName)
// match `DB::select()` or `Model::selectRaw()`
|| !($methodName === 'select' || str_ends_with($methodName, 'Raw'))
|| !('select' === $methodName || str_ends_with($methodName, 'Raw'))
// match `DB::raw()`
|| !str_ends_with($childClassName, 'DB') || 'raw' !== $childMethodName
) {
Expand Down

0 comments on commit d1810ba

Please sign in to comment.