-
-
Notifications
You must be signed in to change notification settings - Fork 188
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: Do proper resolving of FusionPathProxy #3358
BUGFIX: Do proper resolving of FusionPathProxy #3358
Conversation
Using `{image.title}` in Fluid when the image is a `FusionPathProxy` does not work. The result is simply `null` instead of the image title. This change fixes that by moving more code down into our own custom `TemplateVariableContainer` from the `StandardVariableProvider`. Fixes neos#3357
|
||
/** | ||
* Provides the variables inside fluid template. Adds TemplateObjectAccessInterface functionality. | ||
* | ||
* @api | ||
*/ | ||
class TemplateVariableContainer extends StandardVariableProvider implements VariableProviderInterface | ||
class TemplateVariableContainer extends StandardVariableProvider |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The interface is implemented by the extended class already…
$subject = $subject->$isMethod(); | ||
continue; | ||
} | ||
$hasMethod = 'has' . $upperCasePropertyName; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is it worth a consideration to use object access here?
And also can it be that we lost certain features over time in fluid like #108?
I cant really judge and am not that invested into it and neither know whats best. But it seems its a bit back and forth ... we seemed to had already such manual implementation once and it got lost it seems?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I did very consciously copy the method as unchanged as possible, to make the difference clearly visible and easy to understand. This will make maintenance easier for our future selves.
About #108 – yes, it seems that was lost. But given the decline of Fluid, I have little interest in fixing that nowish, and certainly not in the scope of this PR…
Looks reasonable to me. |
Flow 8.x only works correctly with typo3fluid 2.7.x - see: neos/flow-development-collection#3038, neos/flow-development-collection#3041 and neos/flow-development-collection#3358
Flow 8.x only works correctly with typo3fluid 2.7.x - see: neos/flow-development-collection#3038, neos/flow-development-collection#3041 and neos/flow-development-collection#3358
Using
{image.title}
in Fluid when the image is aFusionPathProxy
does not work. The result is simplynull
instead of the image title.This change fixes that by moving more code down into our own custom
TemplateVariableContainer
from theStandardVariableProvider
.Fixes #3357
Review instructions
The fixed issue contains instructions on how to reproduce this.
Checklist
The PR is created against the lowest maintained branchFEATURE|TASK|BUGFIX
Reviewer - Breaking Changes are marked with!!!
and have upgrade-instructions