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

replace isURL usage with isValidURL #1813

Merged
merged 6 commits into from
Jun 2, 2023
Merged

replace isURL usage with isValidURL #1813

merged 6 commits into from
Jun 2, 2023

Conversation

paninaro
Copy link
Contributor

@paninaro paninaro commented Jun 1, 2023

Some NFTs have content URLs containing unencoded spaces. While most of the code handles this without any trouble, the isURL function from the validator library will return false, causing these NFTs to fail to load.

This change introduces an isValidURL function that will encode URLs if necessary and then return the result of isURL(encodedURL).

Tested with NFTs that have encoded and unencoded spaces.

@paninaro paninaro requested a review from seeden June 1, 2023 00:44
@paninaro paninaro merged commit a355f9a into main Jun 2, 2023
@paninaro paninaro deleted the paninaro.isValidURL branch June 2, 2023 16:40
paninaro added a commit to Chia-Network/chia-blockchain that referenced this pull request Jun 5, 2023
* add tests covering WalletService RPCs and related functions by @paninaro in Chia-Network/chia-blockchain-gui#1796
* disconnect sessions when disconnecting a WC pairing by @paninaro in Chia-Network/chia-blockchain-gui#1816
* fixed switching between keys by @seeden in Chia-Network/chia-blockchain-gui#1815
* replace isURL usage with isValidURL by @paninaro in Chia-Network/chia-blockchain-gui#1813
* small bug fixes by @seeden in Chia-Network/chia-blockchain-gui#1818
* [Snyk] Security upgrade vite from 3.1.1 to 3.2.7 by @ChiaAutomation in Chia-Network/chia-blockchain-gui#1819
* Add clawback feature to the GUI by @zsolt-dev in Chia-Network/chia-blockchain-gui#1802
* Rifeljm/#1699 verifiable credentials by @rifeljm in Chia-Network/chia-blockchain-gui#1820

**Full Changelog**: Chia-Network/chia-blockchain-gui@1.8.2-rc1...1.8.2-rc2
wallentx pushed a commit to Chia-Network/chia-blockchain that referenced this pull request Jun 6, 2023
Bump chia-blockchain-gui to 60491b6c68cec864fa6169ffca77db5ca3086399

* add tests covering WalletService RPCs and related functions by @paninaro in Chia-Network/chia-blockchain-gui#1796
* disconnect sessions when disconnecting a WC pairing by @paninaro in Chia-Network/chia-blockchain-gui#1816
* fixed switching between keys by @seeden in Chia-Network/chia-blockchain-gui#1815
* replace isURL usage with isValidURL by @paninaro in Chia-Network/chia-blockchain-gui#1813
* small bug fixes by @seeden in Chia-Network/chia-blockchain-gui#1818
* [Snyk] Security upgrade vite from 3.1.1 to 3.2.7 by @ChiaAutomation in Chia-Network/chia-blockchain-gui#1819
* Add clawback feature to the GUI by @zsolt-dev in Chia-Network/chia-blockchain-gui#1802
* Rifeljm/#1699 verifiable credentials by @rifeljm in Chia-Network/chia-blockchain-gui#1820

**Full Changelog**: Chia-Network/chia-blockchain-gui@1.8.2-rc1...1.8.2-rc2
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