avoid error when trying to access typeProvider attribute for wrong objects
This commit is contained in:
parent
75fff86351
commit
7bf87c15ac
1 changed files with 2 additions and 0 deletions
|
@ -538,6 +538,8 @@ class BaseView(GenericView, I18NView):
|
||||||
|
|
||||||
@Lazy
|
@Lazy
|
||||||
def typeOptions(self):
|
def typeOptions(self):
|
||||||
|
if self.typeProvider is None:
|
||||||
|
return DummyOptions()
|
||||||
return IOptions(adapted(self.typeProvider))
|
return IOptions(adapted(self.typeProvider))
|
||||||
|
|
||||||
def getPredicateOptions(self, relation):
|
def getPredicateOptions(self, relation):
|
||||||
|
|
Loading…
Add table
Reference in a new issue