From: Jan Szejko Date: Tue, 31 Jan 2017 10:56:16 +0000 (+0100) Subject: accept internet/Internet in dc:requires X-Git-Url: https://git.mdrn.pl/edumed.git/commitdiff_plain/3c1674d821a479e38d70d61dd6feeb709bf18702?ds=sidebyside;hp=a6f780f0af1886447399563c9abc053e517d4ca0 accept internet/Internet in dc:requires --- diff --git a/catalogue/models.py b/catalogue/models.py index 9bd5f7e..75feba1 100644 --- a/catalogue/models.py +++ b/catalogue/models.py @@ -289,7 +289,7 @@ class Lesson(models.Model): return None def requires_internet(self): - return 'internet' in self.dc.get('requires', []) + return any(requirement in self.dc.get('requires', []) for requirement in ('internet', 'Internet')) class Attachment(models.Model):