Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Optimized django.utils.functional.curry. Thanks for the patch, Martin…

… Glueck

git-svn-id: http://code.djangoproject.com/svn/django/trunk@3733 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit 29ba3e337bd9c95d059eeae55a3743b675c21150 1 parent 6152b32
@adrianholovaty adrianholovaty authored
Showing with 2 additions and 2 deletions.
  1. +2 −2 django/utils/functional.py
View
4 django/utils/functional.py
@@ -1,6 +1,6 @@
-def curry(*args, **kwargs):
+def curry(func, *args, **kwargs):
def _curried(*moreargs, **morekwargs):
- return args[0](*(args[1:]+moreargs), **dict(kwargs.items() + morekwargs.items()))
+ return func(*(args+moreargs), **dict(kwargs, **morekwargs))
return _curried
class Promise:
Please sign in to comment.
Something went wrong with that request. Please try again.