ourzora / offchain

NFT Metadata made easy
MIT License
109 stars 27 forks source link

escape base64 encoded json token uri strings #74

Closed lara-jeftic closed 10 months ago

lara-jeftic commented 1 year ago

Description

If a token uri is a base64 encoded json, there is a chance the json string is incorrectly escaped and therefore unparseable. this PR attempts to parse the json and if it fails, it escapes the json correctly and then parses it.

Motivation and Context

see ticket here: (https://linear.app/ourzora/issue/CHAIN-790/move-token-uri-escaping-functionality-to-offchain-lib)

How has this been tested?

Screenshots (if appropriate):

Types of changes

Checklist: