change None to undefined when it's needed
This commit is contained in:
@ -24,7 +24,7 @@ from types import FunctionType
|
||||
import warnings
|
||||
|
||||
from tiramisu.i18n import _
|
||||
from tiramisu.setting import log
|
||||
from tiramisu.setting import log, undefined
|
||||
from tiramisu.autolib import carry_out_calculation
|
||||
from tiramisu.error import ConfigError, ValueWarning
|
||||
|
||||
@ -164,14 +164,14 @@ class BaseOption(object):
|
||||
"""
|
||||
self._impl_informations[key] = value
|
||||
|
||||
def impl_get_information(self, key, default=None):
|
||||
def impl_get_information(self, key, default=undefined):
|
||||
"""retrieves one information's item
|
||||
|
||||
:param key: the item string (ex: "help")
|
||||
"""
|
||||
if key in self._impl_informations:
|
||||
return self._impl_informations[key]
|
||||
elif default is not None:
|
||||
elif default is not undefined:
|
||||
return default
|
||||
else:
|
||||
raise ValueError(_("information's item not found: {0}").format(
|
||||
|
Reference in New Issue
Block a user