Skip to content

Instantly share code, notes, and snippets.

@guerbai
Created June 2, 2019 05:08
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save guerbai/1b60fa4e4b367aee39aea98940352303 to your computer and use it in GitHub Desktop.
Save guerbai/1b60fa4e4b367aee39aea98940352303 to your computer and use it in GitHub Desktop.
pop_none
class ValueProcessUtils(object):
@classmethod
def pop_none(cls, **kwargs):
params = dict()
for key, value in kwargs.iteritems():
if value is not None:
params.update({key: value})
return params
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment