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

TASK: Use getClassNameByObjectName instead of manually traversing `… #3322

Closed
wants to merge 1 commit into from

Conversation

mhsdesign
Copy link
Member

…CONFIGURATION_TYPE_OBJECTS`

We were to blind to see it in #3318 but thankfully christian noticed it the last second:

For the respective use case we already HAVE a way better way to do this, namely:

\Neos\Flow\ObjectManagement\ObjectManagerInterface::getClassNameByObjectName(), this should just return the right implementation as in, the chosen one the objectmanager would inject if you asked it, and that's all we need and we have an object manager, at least compiletime which also can answer this question.

Upgrade instructions

Review instructions

Checklist

  • Code follows the PSR-2 coding style
  • Tests have been created, run and adjusted as needed
  • The PR is created against the lowest maintained branch
  • Reviewer - PR Title is brief but complete and starts with FEATURE|TASK|BUGFIX
  • Reviewer - The first section explains the change briefly for change-logs
  • Reviewer - Breaking Changes are marked with !!! and have upgrade-instructions

…CONFIGURATION_TYPE_OBJECTS`

We were to blind to see it in #3318 but thankfully christian noticed it the last second:

> For the respective use case we already HAVE a way better way to do this, namely:

> `\Neos\Flow\ObjectManagement\ObjectManagerInterface::getClassNameByObjectName()`, this should just return the _right_ implementation as in, the chosen one the objectmanager would inject if you asked it, and that's all we need and we have an object manager, at least compiletime which also can answer this question.
@mhsdesign
Copy link
Member Author

@kitsunet sadly not:

The Object Manager is not available at this stage of the bootstrap run.

@Sebobo
Copy link
Member

Sebobo commented Feb 22, 2024

Jepp, doesn't work.

@kitsunet
Copy link
Member

That is disappointing :/
Right because the ObjectManager needs the Flow_Object_Configuration cache which contains exactly the information we need 🐓🥚

@kitsunet
Copy link
Member

Nothing we can fix short term I guess :/

@kitsunet kitsunet closed this Feb 22, 2024
@kitsunet kitsunet reopened this Feb 22, 2024
@kitsunet kitsunet closed this Feb 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants