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

Stop passing empty values to retrieveDownloadUrlFromResourceMapper #4342

Merged
merged 2 commits into from
Nov 18, 2024

Conversation

janette
Copy link
Member

@janette janette commented Nov 15, 2024

This is annoying
Screenshot 2024-11-14 at 7 53 43 PM

When removing old revisions, many nodes without downloadUrls were getting passed to LifeCycle::distributionLoad
which then calls retrieveDownloadUrlFromResourceMapper on non-existent $resourceIdentifier values.

Describe your changes

Changing the check from isset to !empty avoids sending non-distribution nodes through the process

Steps to reproduce

  • Add a logger in distributionLoad to confirm empty $resourceIdentifier values are being sent through retrieveDownloadUrlFromResourceMapper
Screenshot 2024-11-14 at 8 01 33 PM

Checklist before requesting review

If any of these are left unchecked, please provide an explanation

  • I have updated or added tests to cover my code
  • I have updated or added documentation

modules/metastore/src/LifeCycle/LifeCycle.php Outdated Show resolved Hide resolved
modules/metastore/src/LifeCycle/LifeCycle.php Outdated Show resolved Hide resolved
@paul-m paul-m merged commit bf01f56 into 2.x Nov 18, 2024
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants