diff --git a/src/hdmf/common/table.py b/src/hdmf/common/table.py index 2a01f1143..e174564af 100644 --- a/src/hdmf/common/table.py +++ b/src/hdmf/common/table.py @@ -16,6 +16,7 @@ from ..container import Container, Data from ..data_utils import DataIO, AbstractDataChunkIterator from ..utils import docval, getargs, ExtenderMeta, popargs, pystr, AllowPositional +from ..term_set import TermSetWrapper @register_class('VectorData') @@ -593,8 +594,8 @@ def add_row(self, **kwargs): if isinstance(col, VectorIndex): continue else: - if col.term_set is not None: - if col.term_set.validate(term=data[colname]): + if isinstance(col.data, TermSetWrapper): + if col.data.termset.validate(term=data[colname]): continue else: bad_data.append(data[colname])