@@ -112492,8 +112492,8 @@ function composeCollection(CN, ctx, token, props, onError) {
112492
112492
tag = kt;
112493
112493
}
112494
112494
else {
112495
- if (kt?.collection ) {
112496
- onError(tagToken, 'BAD_COLLECTION_TYPE', `${kt.tag} used for ${expType} collection, but expects ${kt.collection}`, true);
112495
+ if (kt) {
112496
+ onError(tagToken, 'BAD_COLLECTION_TYPE', `${kt.tag} used for ${expType} collection, but expects ${kt.collection ?? 'scalar' }`, true);
112497
112497
}
112498
112498
else {
112499
112499
onError(tagToken, 'TAG_RESOLVE_FAILED', `Unresolved tag: ${tagName}`, true);
@@ -117958,7 +117958,20 @@ class Parser {
117958
117958
default: {
117959
117959
const bv = this.startBlockValue(map);
117960
117960
if (bv) {
117961
- if (atMapIndent && bv.type !== 'block-seq') {
117961
+ if (bv.type === 'block-seq') {
117962
+ if (!it.explicitKey &&
117963
+ it.sep &&
117964
+ !includesToken(it.sep, 'newline')) {
117965
+ yield* this.pop({
117966
+ type: 'error',
117967
+ offset: this.offset,
117968
+ message: 'Unexpected block-seq-ind on same line with key',
117969
+ source: this.source
117970
+ });
117971
+ return;
117972
+ }
117973
+ }
117974
+ else if (atMapIndent) {
117962
117975
map.items.push({ start });
117963
117976
}
117964
117977
this.stack.push(bv);
@@ -118897,6 +118910,8 @@ const binary = {
118897
118910
}
118898
118911
},
118899
118912
stringify({ comment, type, value }, ctx, onComment, onChompKeep) {
118913
+ if (!value)
118914
+ return '';
118900
118915
const buf = value; // checked earlier by binary.identify()
118901
118916
let str;
118902
118917
if (typeof node_buffer.Buffer === 'function') {
@@ -119620,7 +119635,7 @@ const timestamp = {
119620
119635
}
119621
119636
return new Date(date);
119622
119637
},
119623
- stringify: ({ value }) => value.toISOString().replace(/(T00:00:00)?\.000Z$/, '')
119638
+ stringify: ({ value }) => value? .toISOString().replace(/(T00:00:00)?\.000Z$/, '') ?? ''
119624
119639
};
119625
119640
119626
119641
exports.floatTime = floatTime;
0 commit comments