summaryrefslogtreecommitdiff
path: root/django/forms/widgets.py
diff options
context:
space:
mode:
Diffstat (limited to 'django/forms/widgets.py')
-rw-r--r--django/forms/widgets.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/django/forms/widgets.py b/django/forms/widgets.py
index 56ff7bb5ad..82498aa662 100644
--- a/django/forms/widgets.py
+++ b/django/forms/widgets.py
@@ -262,6 +262,8 @@ class Media:
return list(dict.fromkeys(chain.from_iterable(filter(None, lists))))
def __add__(self, other):
+ if not isinstance(other, Media):
+ return NotImplemented
combined = Media()
combined._css_lists = self._css_lists[:]
combined._js_lists = self._js_lists[:]