@ember-data/serializer 4.2.0-alpha.8 → 4.2.0-alpha.9
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/addon/rest.js +5 -17
- package/package.json +7 -7
package/addon/rest.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* @module @ember-data/serializer/rest
|
|
3
3
|
*/
|
|
4
4
|
import { makeArray } from '@ember/array';
|
|
5
|
-
import { assert,
|
|
5
|
+
import { assert, warn } from '@ember/debug';
|
|
6
6
|
import { camelize } from '@ember/string';
|
|
7
7
|
import { isNone, typeOf } from '@ember/utils';
|
|
8
8
|
import { DEBUG } from '@glimmer/env';
|
|
@@ -284,22 +284,10 @@ const RESTSerializer = JSONSerializer.extend({
|
|
|
284
284
|
continue;
|
|
285
285
|
}
|
|
286
286
|
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
deprecate(message, !isQueryRecordAnArray, {
|
|
293
|
-
id: 'ds.serializer.rest.queryRecord-array-response',
|
|
294
|
-
until: '3.0',
|
|
295
|
-
url: 'https://deprecations.emberjs.com/ember-data/v2.x/#toc_store-queryrecord-array-response-with-restserializer',
|
|
296
|
-
for: '@ember-data/serializer',
|
|
297
|
-
since: {
|
|
298
|
-
available: '3.0',
|
|
299
|
-
enabled: '3.0',
|
|
300
|
-
},
|
|
301
|
-
});
|
|
302
|
-
}
|
|
287
|
+
assert(
|
|
288
|
+
'The adapter returned an array for the primary data of a `queryRecord` response. `queryRecord` should return a single record.',
|
|
289
|
+
!(requestType === 'queryRecord' && isPrimary && Array.isArray(value))
|
|
290
|
+
);
|
|
303
291
|
|
|
304
292
|
/*
|
|
305
293
|
Support primary data as an object instead of an array.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ember-data/serializer",
|
|
3
|
-
"version": "4.2.0-alpha.
|
|
3
|
+
"version": "4.2.0-alpha.9",
|
|
4
4
|
"description": "The default blueprint for ember-cli addons.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"ember-addon"
|
|
@@ -18,15 +18,15 @@
|
|
|
18
18
|
"test:node": "mocha"
|
|
19
19
|
},
|
|
20
20
|
"dependencies": {
|
|
21
|
-
"@ember-data/private-build-infra": "4.2.0-alpha.
|
|
22
|
-
"@ember-data/store": "4.2.0-alpha.
|
|
21
|
+
"@ember-data/private-build-infra": "4.2.0-alpha.9",
|
|
22
|
+
"@ember-data/store": "4.2.0-alpha.9",
|
|
23
23
|
"ember-auto-import": "^2.2.4",
|
|
24
|
-
"ember-cli-babel": "^7.26.
|
|
24
|
+
"ember-cli-babel": "^7.26.11",
|
|
25
25
|
"ember-cli-test-info": "^1.0.0",
|
|
26
|
-
"ember-cli-typescript": "^
|
|
26
|
+
"ember-cli-typescript": "^5.0.0"
|
|
27
27
|
},
|
|
28
28
|
"devDependencies": {
|
|
29
|
-
"@ember-data/unpublished-test-infra": "4.2.0-alpha.
|
|
29
|
+
"@ember-data/unpublished-test-infra": "4.2.0-alpha.9",
|
|
30
30
|
"@ember/optional-features": "^2.0.0",
|
|
31
31
|
"@ember/string": "^3.0.0",
|
|
32
32
|
"@ember/test-helpers": "^2.6.0",
|
|
@@ -48,7 +48,7 @@
|
|
|
48
48
|
"ember-source-channel-url": "^3.0.0",
|
|
49
49
|
"ember-try": "^1.4.0",
|
|
50
50
|
"loader.js": "^4.7.0",
|
|
51
|
-
"qunit": "^2.
|
|
51
|
+
"qunit": "^2.17.0",
|
|
52
52
|
"qunit-dom": "^2.0.0",
|
|
53
53
|
"silent-error": "^1.1.1",
|
|
54
54
|
"webpack": "^5.37.1"
|