Revert "added null check to NamedEntity"

This reverts commit fdc542a86cb310777a431c3c678cab75f1414832.