diff --git a/molgenis-data-mapper/src/main/java/org/molgenis/data/mapper/algorithmgenerator/rules/impl/InternalAbstractCategoryRule.java b/molgenis-data-mapper/src/main/java/org/molgenis/data/mapper/algorithmgenerator/rules/impl/InternalAbstractCategoryRule.java
index <HASH>..<HASH> 100644
--- a/molgenis-data-mapper/src/main/java/org/molgenis/data/mapper/algorithmgenerator/rules/impl/InternalAbstractCategoryRule.java
+++ b/molgenis-data-mapper/src/main/java/org/molgenis/data/mapper/algorithmgenerator/rules/impl/InternalAbstractCategoryRule.java
@@ -1,5 +1,6 @@
 package org.molgenis.data.mapper.algorithmgenerator.rules.impl;
 
+import java.util.Objects;
 import java.util.Set;
 
 import org.apache.commons.lang3.StringUtils;
@@ -16,7 +17,7 @@ public abstract class InternalAbstractCategoryRule implements CategoryRule
 
 	public InternalAbstractCategoryRule(Set<String> words)
 	{
-		this.words = words;
+		this.words = Objects.requireNonNull(words);
 	}
 
 	@Override
added a nonNon check in constructor for InternalAbstractCategoryRule