Skip to content

Commit c881e9a

Browse files
committed
Fix JSON literal value version 1 check.
1 parent 8a05098 commit c881e9a

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lib/expand.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -769,9 +769,9 @@ async function _expandObject({
769769

770770
// @value must not be an object or an array (unless framing) or if @type is
771771
// @json
772-
if('@value' in element) {
773-
const value = element['@value'];
774-
if(element['@type'] === '@json' && _processingMode(activeCtx, 1.1)) {
772+
if('@value' in expandedParent) {
773+
const value = expandedParent['@value'];
774+
if(expandedParent['@type'] === '@json' && _processingMode(activeCtx, 1.1)) {
775775
// allow any value, to be verified when the object is fully expanded and
776776
// the @type is @json.
777777
} else if((_isObject(value) || _isArray(value)) && !options.isFrame) {

0 commit comments

Comments
 (0)