Added ability to set material otf file to None

This commit is contained in:
Nicholas Horelik 2014-12-01 23:52:29 -05:00
parent 8c3789cb78
commit 9decb858e2

View file

@ -224,7 +224,7 @@ class Material(object):
warnings.warn('This feature is not yet implemented in a release ' \
'version of openmc')
if not is_string(name):
if not is_string(name) and not name is None:
msg = 'Unable to add OTF material file to Material ID={0} with a ' \
'non-string name {1}'.format(self._id, name)
raise ValueError(msg)