File tree Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -484,6 +484,7 @@ api.createTermDefinition = (
484484 if ( value [ '@protected' ] === true ||
485485 ( defined . get ( '@protected' ) === true && value [ '@protected' ] !== false ) ) {
486486 activeCtx . protected [ term ] = true ;
487+ mapping . protected = true ;
487488 }
488489
489490 // IRI mapping now defined
@@ -982,8 +983,16 @@ api.getInitialContext = options => {
982983 if ( mapping . isTypeScopedTerm ) {
983984 if ( mapping . previousMapping ) {
984985 child . mappings . set ( term , mapping . previousMapping ) ;
986+ if ( mapping . previousMapping . protected ) {
987+ child . protected [ term ] = true ;
988+ } else {
989+ delete child . protected [ term ] ;
990+ }
985991 } else {
986992 child . mappings . delete ( term ) ;
993+ if ( child . protected [ term ] ) {
994+ delete child . protected [ term ] ;
995+ }
987996 }
988997 }
989998 }
You can’t perform that action at this time.
0 commit comments