File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change 13
13
- ` @vocab ` can be relative or a Compact IRI in 1.1, resolved against either a previous ` @vocab ` ,
14
14
` @base ` or document base.
15
15
- Better checking of absolute IRIs.
16
- - Terms that beging with a ':' are not considered absolute or compact IRIs.
16
+ - Terms that beggining with a ':' are not considered absolute or compact IRIs.
17
17
- Don't use terms with ` @prefix ` : false, or expanded term definitions to construct compact IRIs.
18
18
19
19
### Removed
Original file line number Diff line number Diff line change @@ -827,9 +827,9 @@ api.compactIri = ({
827
827
// If iri could be confused with a compact IRI using a term in this context,
828
828
// signal an error
829
829
for ( const [ term , td ] of activeCtx . mappings ) {
830
- if ( iri . startsWith ( term + ':' ) && td . _prefix ) {
830
+ if ( td . _prefix && iri . startsWith ( term + ':' ) ) {
831
831
throw new JsonLdError (
832
- ( ' Absolute IRI "' + iri + ' " confused with prefix "' + term + '"' ) ,
832
+ ( ` Absolute IRI "${ iri } " confused with prefix "${ term } ".` ) ,
833
833
'jsonld.SyntaxError' ,
834
834
{ code : 'IRI confused with prefix' , context : activeCtx } ) ;
835
835
}
You can’t perform that action at this time.
0 commit comments