index is an str
This commit is contained in:
parent
dae6779e72
commit
34e7a86130
@ -627,7 +627,6 @@ class Config:
|
||||
def is_hidden(self,
|
||||
path: str,
|
||||
index: Optional[int]) -> bool:
|
||||
property_ = 'hidden'
|
||||
for property_, needs in {'hidden': True, 'display': False}.items():
|
||||
if property_ in self.temp.get(path, {}):
|
||||
value = self.temp[path][property_]
|
||||
@ -638,7 +637,7 @@ class Config:
|
||||
elif self.model.get(path, {}).get(property_, None) == needs:
|
||||
return True
|
||||
index = str(index)
|
||||
if index is not None and index in self.model.get(path, {}) and self.model.get(path, {}).get(index, {}).get(property_, None) == needs:
|
||||
if index != 'None' and index in self.model.get(path, {}) and self.model.get(path, {}).get(index, {}).get(property_, None) == needs:
|
||||
return True
|
||||
return False
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user