/gist:67af029321018ec1c49f Secret
Last active
January 3, 2016 01:49
-
-
Save rweir/67af029321018ec1c49f to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
newdict = {} | |
for key, value in sorted(file.iteritems()): | |
action = actions.get(key) | |
if action: | |
newdict[key] = functools.partial(action, value) | |
else: | |
newdict[key] = lambda _: value | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment