MCPcopy Create free account
hub / github.com/parse-community/parse-server / isPath

Method isPath

src/Utils.js:97–99  ·  view source on GitHub ↗

* @function isPath * @description Evaluates whether a string is a file path (as opposed to a URL for example). * @param {String} s The string to evaluate. * @returns {Boolean} Returns true if the evaluated string is a path.

(s)

Source from the content-addressed store, hash-verified

95 * @returns {Boolean} Returns true if the evaluated string is a path.
96 */
97 static isPath(s) {
98 return /(^\/)|(^\.\/)|(^\.\.\/)/.test(s);
99 }
100
101 /**
102 * Flattens an object and crates new keys with custom delimiters.

Callers 1

goToPageMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected