diff --git a/src/agenda_culturel/models.py b/src/agenda_culturel/models.py index 3fb32c5..fee31d1 100644 --- a/src/agenda_culturel/models.py +++ b/src/agenda_culturel/models.py @@ -2050,6 +2050,16 @@ class Event(models.Model): self.has_invalid_start_time() or event.has_invalid_start_time() ): continue + # only consider path for Facebook urls + if ( + r["key"] == "image" + and len(r["values"]) > 0 + and "fbcdn.net" in r["values"][0] + ): + nb = len(set([urlparse(url).path for url in r["values"]])) + if nb == 1: + continue + return False return True