No flags found
Use flags to group coverage reports by test type, project and/or folders.
Then setup custom commit statuses and notifications for each flag.
e.g., #unittest #integration
#production #enterprise
#frontend #backend
094fbe2
... +23 ...
7362468
Use flags to group coverage reports by test type, project and/or folders.
Then setup custom commit statuses and notifications for each flag.
e.g., #unittest #integration
#production #enterprise
#frontend #backend
2399 | 2399 | if (el instanceof ParseFile) { |
|
2400 | 2400 | filesSaved.push(el.save(options)); |
|
2401 | 2401 | } else if (el instanceof ParseObject) { |
|
2402 | - | if (allowCustomObjectId && !el.id) { |
|
2403 | - | throw new ParseError( |
|
2404 | - | ParseError.MISSING_OBJECT_ID, |
|
2405 | - | 'objectId must not be empty, null or undefined' |
|
2406 | - | ); |
|
2407 | - | } |
|
2408 | 2402 | pending.push(el); |
|
2409 | 2403 | } |
|
2410 | 2404 | }); |
2419 | 2413 | const batch = []; |
|
2420 | 2414 | const nextPending = []; |
|
2421 | 2415 | pending.forEach(el => { |
|
2416 | + | if (allowCustomObjectId && Object.prototype.hasOwnProperty.call(el, 'id') && !el.id) { |
|
2417 | + | throw new ParseError( |
|
2418 | + | ParseError.MISSING_OBJECT_ID, |
|
2419 | + | 'objectId must not be empty or null' |
|
2420 | + | ); |
|
2421 | + | } |
|
2422 | + | ||
2422 | 2423 | if (batch.length < batchSize && canBeSerialized(el)) { |
|
2423 | 2424 | batch.push(el); |
|
2424 | 2425 | } else { |
2498 | 2499 | }); |
|
2499 | 2500 | }); |
|
2500 | 2501 | } else if (target instanceof ParseObject) { |
|
2501 | - | if (allowCustomObjectId && !target.id) { |
|
2502 | - | throw new ParseError( |
|
2503 | - | ParseError.MISSING_OBJECT_ID, |
|
2504 | - | 'objectId must not be empty, null or undefined' |
|
2505 | - | ); |
|
2502 | + | if (allowCustomObjectId && Object.prototype.hasOwnProperty.call(target, 'id') && !target.id) { |
|
2503 | + | throw new ParseError(ParseError.MISSING_OBJECT_ID, 'objectId must not be empty or null'); |
|
2506 | 2504 | } |
|
2507 | 2505 | // generate _localId in case if cascadeSave=false |
|
2508 | 2506 | target._getId(); |
Files | Coverage |
---|---|
src | 99.95% |
Project Totals (61 files) | 99.95% |
#1540
7362468
04748d6
7e3b18f
#1540
6bbb054
#1540
7155872
2d6ffb7
#1540
41e61b5
51f6678
#1540
ee5498e
b443f84
0399ee6
79fcf83
55ecd1b
e8971a4
43e96b3
872aadb
9f53d1a
2455fcb
91e425f
b3b3365
2298855
#1540
ec80a44
a88e8ae
78729bb
094fbe2