js-stellar-sdk icon indicating copy to clipboard operation
js-stellar-sdk copied to clipboard

Allow for handling of redirects of URL to stellar.toml

Open KyleSmith19091 opened this issue 1 year ago • 1 comments

Is your feature request related to a problem? Please describe. Experienced an issue when trying to resolve the stellar.toml for this EURC issued asset, which when this URL is accessed redirects you to a different url where the toml file is hosted. I understand this might go against the standard set by the stellar foundation, but I feel like you should be able to have a flag that can handle redirects when trying to resolve the domain. If this is not wide issue I understand if this issue is not considered

Describe the solution you'd like Add a flag to the Resolver.resolve options object to set some number of redirects which can then be passed the axios.get function.

Describe alternatives you've considered I had to write custom logic on top of the stellar Resolver.resolve function to correctly handle this case.

KyleSmith19091 avatar Sep 20 '24 07:09 KyleSmith19091

Proposed solution: https://github.com/stellar/js-stellar-sdk/pull/1053

KyleSmith19091 avatar Sep 20 '24 07:09 KyleSmith19091