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

Prototype #25

Closed
wants to merge 1 commit into from
Closed

Prototype #25

wants to merge 1 commit into from

Conversation

rdss-sknott
Copy link
Contributor

No description provided.

@rdss-sknott rdss-sknott self-assigned this Feb 26, 2024
@@ -141,7 +149,7 @@ public function process(File $phpcsFile, $stackPtr)
$phpcsFile->fixer->replaceToken(($i - 1), $padding);
}
}
}
}//end if
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤯

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This for loop needs refactoring 😉

@@ -162,6 +170,7 @@ public function process(File $phpcsFile, $stackPtr)
&& $tokens[($i + 1)]['content'] !== ' '
&& strtolower(substr($tokens[($i + 1)]['content'], 0, 3)) !== '@oa'
&& strtolower(substr($tokens[($i + 2)]['content'], 0, 3)) !== '@oa'
&& !str_starts_with(strtolower($tokens[($i + 1)]['content']), '@orm')
Copy link
Contributor

@matthias-ruester matthias-ruester Feb 26, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why using brackets in all the index statements? $i + 1 should work as expected without using ()

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As this was just a core hack to learn if it helps solving your problem I wouldn't go too deep into that. ^

@rdss-sknott rdss-sknott deleted the orm-annotation-spacing branch March 13, 2024 08:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants