add global 'empty' property, this property raise mandatory PropertiesOptionError if multi or master have empty value

This commit is contained in:
2015-07-26 18:55:21 +02:00
parent 1da83edfba
commit 8e7a32de08
7 changed files with 145 additions and 22 deletions

View File

@ -79,7 +79,7 @@ class StorageBase(object):
self._properties = properties
if opt is not undefined:
self._opt = opt
if allow_empty_list is not False:
if allow_empty_list is not undefined:
self._allow_empty_list = allow_empty_list
def _set_default_values(self, default, default_multi):
@ -302,8 +302,7 @@ class StorageBase(object):
try:
return self._allow_empty_list
except AttributeError:
return False
return undefined
def _get_extra(self, key):
extra = self._extra