Skip to content

Instantly share code, notes, and snippets.

@Ram-Z
Last active November 21, 2016 21:39
Show Gist options
  • Save Ram-Z/265dd3e6482db9d93d09d60ac407e04b to your computer and use it in GitHub Desktop.
Save Ram-Z/265dd3e6482db9d93d09d60ac407e04b to your computer and use it in GitHub Desktop.
diff --git a/flexget/plugins/filter/require_field.py b/flexget/plugins/filter/require_field.py
index d9a0016..3d32859 100644
--- a/flexget/plugins/filter/require_field.py
+++ b/flexget/plugins/filter/require_field.py
@@ -31,6 +31,9 @@ class FilterRequireField(object):
if field not in entry:
entry.reject('Required field %s is not present' % field)
break
+ if entry[field] is None:
+ entry.reject('Required field %s is `None`' % field)
+ break
@event('plugin.register') 
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment