From b19c982f8cc1f302b759a901fce402c0649ede69 Mon Sep 17 00:00:00 2001 From: Oleg Marshev Date: Thu, 7 Nov 2013 15:25:20 +0200 Subject: [PATCH] Allow any part of protocol name to be lowercase or uppercase (BLD-496). --- cms/djangoapps/contentstore/views/item.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cms/djangoapps/contentstore/views/item.py b/cms/djangoapps/contentstore/views/item.py index 41da5586b0..a5a4ef7ba6 100644 --- a/cms/djangoapps/contentstore/views/item.py +++ b/cms/djangoapps/contentstore/views/item.py @@ -142,7 +142,7 @@ def save_item(request): # security will reject non-https URLs anyway. # Also, following video module specific code is here, because front-end # metadata fields doesn't support validation. - if metadata_key == 'html5_sources' and not all([parse_url(u).scheme in allowedSchemes for u in value]): + if metadata_key == 'html5_sources' and not all([parse_url(u).scheme.lower() in allowedSchemes for u in value]): raise ValidationError(u'HTML5 video sources support following protocols: {0}.'.format(' '.join(allowedSchemes))) # Save the data that we've just changed to the underlying # MongoKeyValueStore before we update the mongo datastore.