[biplan] detect invalid events

This commit is contained in:
Bezleputh 2014-12-09 10:36:14 +01:00 committed by Florent
commit 77d5e6b0f4
2 changed files with 3 additions and 3 deletions

View file

@ -88,7 +88,7 @@ class ProgramPage(HTMLPage):
return BiplanCalendarEventConcert() if self.env['is_concert'] else BiplanCalendarEventTheatre()
def condition(self):
return (self.el.xpath('./div'))
return (self.el.xpath('./div') and CleanText('./div/a/img/@src')(self)[-1] != '/')
def validate(self, obj):
return (self.is_valid_event(obj, self.env['city'], self.env['categories']) and