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

SubstituteConstantsModeAndRequestTypeRector does wrong convertion #4216

Open
simonschaufi opened this issue Apr 5, 2024 · 3 comments
Open
Labels

Comments

@simonschaufi
Copy link
Collaborator

Bug Report

Minimal PHP Code Causing Issue

-        if (!(TYPO3_REQUESTTYPE & TYPO3_REQUESTTYPE_FE)) {
+        if (!(TYPO3_REQUESTTYPE & ApplicationType::fromRequest($GLOBALS['TYPO3_REQUEST'])->isFrontend())) {
             return null;
         }

Expected Behaviour

-        if (!(TYPO3_REQUESTTYPE & TYPO3_REQUESTTYPE_FE)) {
+        if (!(ApplicationType::fromRequest($GLOBALS['TYPO3_REQUEST'])->isFrontend())) {
             return null;
         }
@sabbelasichon
Copy link
Owner

@helsner
Copy link
Collaborator

helsner commented May 25, 2024

i merged my PR for this one #4256 and found this issue afterwards
maybe it is already patched with that?

@helsner
Copy link
Collaborator

helsner commented May 27, 2024

just checked - it's not fixed with the other PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants