Azure / AppConfiguration-JavaScriptProvider

The configuration provider for consuming data in Azure App Configuration from JavaScript applications like Node or browser apps.
https://github.com/Azure/AppConfiguration
MIT License
7 stars 1 forks source link

fix bug on parsing special JSON values #15

Closed Eskibear closed 11 months ago

Eskibear commented 11 months ago

As discussed in https://github.com/Azure/AppConfiguration-JavaScriptProvider/pull/8#discussion_r1329314727 , we should silent fail and fallback to use the string value when it fails to be parsed as a JSON value.

Found a miss here when the value is null, which is legal according to RFC4627 and AppConfig service's behavior.

This PR fixes the bug and I also include test cases for special values.