Crash when looking for a place within an area

Fixes #10531
This commit is contained in:
SNoiraud 2018-04-04 20:32:38 +02:00 committed by Nick Hall
parent 09ca223f1b
commit 17ffc5460c

View File

@ -133,13 +133,13 @@ class PlaceSidebarFilter(SidebarFilter):
code = str(self.filter_code.get_text()).strip() code = str(self.filter_code.get_text()).strip()
enclosed = str(self.filter_enclosed.get_text()).strip() enclosed = str(self.filter_enclosed.get_text()).strip()
note = str(self.filter_note.get_text()).strip() note = str(self.filter_note.get_text()).strip()
within = self.filter_within.get_value()[0] within = self.filter_within.get_value()
regex = self.filter_regex.get_active() regex = self.filter_regex.get_active()
tag = self.tag.get_active() > 0 tag = self.tag.get_active() > 0
gen = self.generic.get_active() > 0 gen = self.generic.get_active() > 0
empty = not (gid or name or ptype or code or enclosed or note or regex empty = not (gid or name or ptype or code or enclosed or note or regex
or within or tag or gen) or within[0] or tag or gen)
if empty: if empty:
generic_filter = None generic_filter = None
else: else: