parse 5.0.0-alpha.2 → 5.0.0-alpha.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/parse.js +33 -3
- package/dist/parse.min.js +2 -2
- package/dist/parse.weapp.js +33 -3
- package/dist/parse.weapp.min.js +2 -2
- package/lib/browser/CoreManager.js +1 -1
- package/lib/browser/ParseQuery.js +31 -1
- package/lib/node/CoreManager.js +1 -1
- package/lib/node/ParseQuery.js +29 -1
- package/lib/react-native/CoreManager.js +1 -1
- package/lib/react-native/ParseQuery.js +21 -1
- package/lib/weapp/CoreManager.js +1 -1
- package/lib/weapp/ParseQuery.js +31 -1
- package/package.json +1 -1
package/dist/parse.weapp.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Parse JavaScript SDK v5.0.0-alpha.
|
|
2
|
+
* Parse JavaScript SDK v5.0.0-alpha.3
|
|
3
3
|
*
|
|
4
4
|
* The source tree of this library can be found at
|
|
5
5
|
* https://github.com/ParsePlatform/Parse-SDK-JS
|
|
@@ -557,7 +557,7 @@ var config /*: Config & { [key: string]: mixed }*/ = {
|
|
|
557
557
|
SERVER_AUTH_TOKEN: null,
|
|
558
558
|
LIVEQUERY_SERVER_URL: null,
|
|
559
559
|
ENCRYPTED_KEY: null,
|
|
560
|
-
VERSION: 'js' + "5.0.0-alpha.
|
|
560
|
+
VERSION: 'js' + "5.0.0-alpha.3",
|
|
561
561
|
APPLICATION_ID: null,
|
|
562
562
|
JAVASCRIPT_KEY: null,
|
|
563
563
|
MASTER_KEY: null,
|
|
@@ -11629,6 +11629,7 @@ var _LocalDatastoreUtils = _dereq_("./LocalDatastoreUtils");
|
|
|
11629
11629
|
readPreference?: string,
|
|
11630
11630
|
includeReadPreference?: string,
|
|
11631
11631
|
subqueryReadPreference?: string,
|
|
11632
|
+
comment?: string,
|
|
11632
11633
|
};*/
|
|
11633
11634
|
/**
|
|
11634
11635
|
* Converts a string into a regex that matches it.
|
|
@@ -11831,6 +11832,7 @@ var ParseQuery = /*#__PURE__*/function () {
|
|
|
11831
11832
|
(0, _defineProperty2.default)(this, "_hint", void 0);
|
|
11832
11833
|
(0, _defineProperty2.default)(this, "_explain", void 0);
|
|
11833
11834
|
(0, _defineProperty2.default)(this, "_xhrRequest", void 0);
|
|
11835
|
+
(0, _defineProperty2.default)(this, "_comment", void 0);
|
|
11834
11836
|
if (typeof objectClass === 'string') {
|
|
11835
11837
|
if (objectClass === 'User' && _CoreManager.default.get('PERFORM_USER_REWRITE')) {
|
|
11836
11838
|
this.className = '_User';
|
|
@@ -11866,6 +11868,7 @@ var ParseQuery = /*#__PURE__*/function () {
|
|
|
11866
11868
|
task: null,
|
|
11867
11869
|
onchange: function () {}
|
|
11868
11870
|
};
|
|
11871
|
+
this._comment = null;
|
|
11869
11872
|
}
|
|
11870
11873
|
|
|
11871
11874
|
/**
|
|
@@ -12082,6 +12085,9 @@ var ParseQuery = /*#__PURE__*/function () {
|
|
|
12082
12085
|
if (this._explain) {
|
|
12083
12086
|
params.explain = true;
|
|
12084
12087
|
}
|
|
12088
|
+
if (this._comment) {
|
|
12089
|
+
params.comment = this._comment;
|
|
12090
|
+
}
|
|
12085
12091
|
for (var _key3 in this._extraOptions) {
|
|
12086
12092
|
params[_key3] = this._extraOptions[_key3];
|
|
12087
12093
|
}
|
|
@@ -12154,10 +12160,13 @@ var ParseQuery = /*#__PURE__*/function () {
|
|
|
12154
12160
|
if (json.explain) {
|
|
12155
12161
|
this._explain = !!json.explain;
|
|
12156
12162
|
}
|
|
12163
|
+
if (json.comment) {
|
|
12164
|
+
this._comment = json.comment;
|
|
12165
|
+
}
|
|
12157
12166
|
for (var _key4 in json) {
|
|
12158
12167
|
if (json.hasOwnProperty(_key4)) {
|
|
12159
12168
|
var _context4;
|
|
12160
|
-
if ((0, _indexOf.default)(_context4 = ['where', 'include', 'keys', 'count', 'limit', 'skip', 'order', 'readPreference', 'includeReadPreference', 'subqueryReadPreference', 'hint', 'explain']).call(_context4, _key4) === -1) {
|
|
12169
|
+
if ((0, _indexOf.default)(_context4 = ['where', 'include', 'keys', 'count', 'limit', 'skip', 'order', 'readPreference', 'includeReadPreference', 'subqueryReadPreference', 'hint', 'explain', 'comment']).call(_context4, _key4) === -1) {
|
|
12161
12170
|
this._extraOptions[_key4] = json[_key4];
|
|
12162
12171
|
}
|
|
12163
12172
|
}
|
|
@@ -13883,6 +13892,27 @@ var ParseQuery = /*#__PURE__*/function () {
|
|
|
13883
13892
|
_this16._xhrRequest.onchange();
|
|
13884
13893
|
};
|
|
13885
13894
|
}
|
|
13895
|
+
|
|
13896
|
+
/**
|
|
13897
|
+
* Sets a comment to the query so that the query
|
|
13898
|
+
*can be identified when using a the profiler for MongoDB.
|
|
13899
|
+
*
|
|
13900
|
+
* @param {string} value a comment can make your profile data easier to interpret and trace.
|
|
13901
|
+
* @returns {Parse.Query} Returns the query, so you can chain this call.
|
|
13902
|
+
*/
|
|
13903
|
+
}, {
|
|
13904
|
+
key: "comment",
|
|
13905
|
+
value: function (value /*: string*/) /*: ParseQuery*/{
|
|
13906
|
+
if (value == null) {
|
|
13907
|
+
delete this._comment;
|
|
13908
|
+
return this;
|
|
13909
|
+
}
|
|
13910
|
+
if (typeof value !== 'string') {
|
|
13911
|
+
throw new Error('The value of a comment to be sent with this query must be a string.');
|
|
13912
|
+
}
|
|
13913
|
+
this._comment = value;
|
|
13914
|
+
return this;
|
|
13915
|
+
}
|
|
13886
13916
|
}], [{
|
|
13887
13917
|
key: "fromJSON",
|
|
13888
13918
|
value: function (className /*: string*/, json /*: QueryJSON*/) /*: ParseQuery*/{
|