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

BUGFIX: Avoid getPath() on null in LinkingService #1984

Merged
merged 1 commit into from
Apr 4, 2018

Conversation

kdambekalns
Copy link
Member

When the context of the "resolved" node does not have a "current" site
in LinkingService.createNodeUri() a fatal error was triggered. This
adds a check and handles the case like a site node path mismatch.

When the context of the "resolved" node does not have a "current" site
in `LinkingService.createNodeUri()` a fatal error was triggered. This
adds a check and handles the case like a site node path mismatch.
Copy link
Member

@kitsunet kitsunet left a comment

Choose a reason for hiding this comment

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

This part is in need of some love but I think at least the ES rewrite is on it anyway...

@bwaidelich
Copy link
Member

I'm not into the LinkingService at all, but in general this check makes sense to me. I only wonder: In which case does this occur and is it fine to "silently" ignore it and fall back?

@kitsunet
Copy link
Member

kitsunet commented Apr 3, 2018

Can happen if said node instance has a CR Context and not a Neos Context. IMHO the whole concept of currentSiteNode() needs to be gone from the Context. The fallback is more or less what should happen all the time, as any given node knows best what site it belongs to.

@kdambekalns kdambekalns merged commit 945e0d4 into neos:3.0 Apr 4, 2018
@kdambekalns kdambekalns deleted the bugfix/sitenode-not-found branch April 4, 2018 07:30
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.

4 participants