Skip to content

Commit

Permalink
Merge pull request #573 from HubSpot/null-disabled
Browse files Browse the repository at this point in the history
Check that disabled library map isn't null
  • Loading branch information
jasmith-hs authored Dec 22, 2020
2 parents 93257ff + c4e3420 commit 27f9eaf
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -356,9 +356,11 @@ public static String buildSetTagForDeferredInChildContext(
if (deferredValuesToSet.size() == 0) {
return "";
}
Map<Library, Set<String>> disabled = interpreter.getConfig().getDisabled();
if (
interpreter.getConfig().getDisabled().containsKey(Library.TAG) &&
interpreter.getConfig().getDisabled().get(Library.TAG).contains(SetTag.TAG_NAME)
disabled != null &&
disabled.containsKey(Library.TAG) &&
disabled.get(Library.TAG).contains(SetTag.TAG_NAME)
) {
throw new DisabledException("set tag disabled");
}
Expand Down

0 comments on commit 27f9eaf

Please sign in to comment.