Skip to content

Commit ddfe3a4

Browse files
committed
Set default for expandAllScripts to true for flatten and toRdf.
1 parent d8f10c2 commit ddfe3a4

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

lib/jsonld.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -387,6 +387,7 @@ jsonld.flatten = async function(input, ctx, options) {
387387
// set default options
388388
options = _setDefaults(options, {
389389
base: _isString(input) ? input : '',
390+
extractAllScripts: true,
390391
contextResolver: new ContextResolver(
391392
{sharedCache: _resolvedContextCache})
392393
});
@@ -656,6 +657,7 @@ jsonld.toRDF = async function(input, options) {
656657
// set default options
657658
options = _setDefaults(options, {
658659
base: _isString(input) ? input : '',
660+
extractAllScripts: true,
659661
skipExpansion: false,
660662
contextResolver: new ContextResolver(
661663
{sharedCache: _resolvedContextCache})

tests/test-common.js

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -151,8 +151,6 @@ const TEST_TYPES = {
151151
specVersion: ['json-ld-1.0'],
152152
// FIXME
153153
idRegex: [
154-
// html
155-
/html-manifest.jsonld#tf004$/,
156154
// included
157155
/flatten-manifest.jsonld#tin01$/,
158156
/flatten-manifest.jsonld#tin02$/,
@@ -309,7 +307,7 @@ const TEST_TYPES = {
309307
/toRdf-manifest.jsonld#twf06$/,
310308
/toRdf-manifest.jsonld#twf07$/,
311309
// html
312-
/html-manifest.jsonld#tr010$/,
310+
// /html-manifest.jsonld#tr010$/, // unescaped content
313311
// number fixes
314312
/toRdf-manifest.jsonld#trt01$/,
315313
// IRI resolution

0 commit comments

Comments
 (0)