Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -499,15 +499,17 @@ private void validateDataRequirements(Library library) {
private void validateTerminologyRequirements(Library library) {
// TODO: Smarter validation would be to checkout and see if any retrieves
// Use terminology, and to check for any codesystem lookups.
if ((library.getCodeSystems() != null
// Please remember that (true) || (true) || (true) && false == true beacause of order of operations, so the
// extra () are needed!
if (((library.getCodeSystems() != null
&& library.getCodeSystems().getDef() != null
&& !library.getCodeSystems().getDef().isEmpty())
|| (library.getCodes() != null
&& library.getCodes().getDef() != null
&& !library.getCodes().getDef().isEmpty())
|| (library.getValueSets() != null
&& library.getValueSets().getDef() != null
&& !library.getValueSets().getDef().isEmpty())
&& !library.getValueSets().getDef().isEmpty()))
&& this.environment.getTerminologyProvider() == null) {
throw new IllegalArgumentException(String.format(
"Library %s has terminology requirements and no terminology provider is registered.",
Expand Down