MCPcopy Index your code
hub / github.com/parse-community/parse-server / removeHiddenProperties

Method removeHiddenProperties

src/Routers/UsersRouter.js:32–41  ·  view source on GitHub ↗

* Removes all "_" prefixed properties from an object, except "__type" * @param {Object} obj An object.

(obj)

Source from the content-addressed store, hash-verified

30 * @param {Object} obj An object.
31 */
32 static removeHiddenProperties(obj) {
33 for (var key in obj) {
34 if (Object.prototype.hasOwnProperty.call(obj, key)) {
35 // Regexp comes from Parse.Object.prototype.validate
36 if (key !== '__type' && !/^[A-Za-z][0-9A-Za-z_]*$/.test(key)) {
37 delete obj[key];
38 }
39 }
40 }
41 }
42
43 /**
44 * After retrieving a user directly from the database, we need to remove the

Callers 5

_inflateParseObjectMethod · 0.80
handleMeMethod · 0.80
handleLogInMethod · 0.80
handleVerifyPasswordMethod · 0.80
handleFindMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected