MCPcopy Create free account
hub / github.com/Starcounter-Jack/JSON-Patch / unescapePathComponent

Function unescapePathComponent

commonjs/helpers.js:95–97  ·  view source on GitHub ↗

* Unescapes a json pointer path * @param path The escaped pointer * @return The unescaped path

(path)

Source from the content-addressed store, hash-verified

93 * @return The unescaped path
94 */
95function unescapePathComponent(path) {
96 return path.replace(/~1/g, '/').replace(/~0/g, '~');
97}
98exports.unescapePathComponent = unescapePathComponent;
99function _getPathRecursive(root, obj) {
100 var found;

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected