BUGFIX: Correct asset download url#262
Merged
Sebobo merged 1 commit intoFlowpack:2.xfrom Sep 16, 2025
Merged
Conversation
jonnitto
requested changes
Sep 7, 2025
jonnitto
approved these changes
Sep 11, 2025
jonnitto
requested changes
Sep 11, 2025
jonnitto
approved these changes
Sep 11, 2025
Sebobo
requested changes
Sep 15, 2025
Member
There was a problem hiding this comment.
Thx for trying to fix this, but your change cannot be right in my opinion.
The $asset can never be a ProvidesOriginalUriInterface as it is a Types\Asset and only the NeosAssetProxy has this method as it implements the interface.
So the condition in line 112 can never be true and it instead always returns the preview uri.
So IMO the correct fix would be to switch from $asset to $assetProxy in the condition.
Also we need to target the 2.x branch with this.
Contributor
Author
|
@Sebobo Yes, I thought so too, see my first commit. Changed it to assetProxy again |
291e852 to
fe362e9
Compare
fe362e9 to
b53c634
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What I did
fix that download always dowloaded the preview png instead of file
#259
How I did it
changed $asset to $assetProxy in condition
I found ProvidesOriginalUriInterface is only implemented in NeosAssetProxy so that makes sense
How to verify it
Download of pdf works again for example