Skip to content

fix: escape license terms URI before id retrieval - #478

Closed
romain-mg wants to merge 1 commit into
thedatafoundation:mainfrom
romain-mg:fix/consistent-hashing
Closed

fix: escape license terms URI before id retrieval#478
romain-mg wants to merge 1 commit into
thedatafoundation:mainfrom
romain-mg:fix/consistent-hashing

Conversation

@romain-mg

Copy link
Copy Markdown

Description

This PR fixes an issue in the PILicenseTemplate.getLicenseTermsId() function.

When license terms are registered using registerLicenseTerms(), the terms URI is escaped before registration.

Problem: the URI was not escaped when retrieving the license terms ID with getLicenseTermsId(), which could cause incorrect lookups if the URI had unusual formatting.

Fix: escape the license terms URI before retrieving the ID.

Testing: test_PILicenseTemplate_getLicenseTermsId_escapeURI registers license terms using a URI that changes when escaped, then verifies that the correct terms ID is retrieved.

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.

1 participant