From de49699ef9eeccc6339f29d2e197d6f26d4904dc Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Sun, 25 Jan 2009 03:10:29 +0000 Subject: Test coverage. --- repoze/bfg/functional.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'repoze/bfg/functional.py') diff --git a/repoze/bfg/functional.py b/repoze/bfg/functional.py index cf196ebd8..351bcc4b6 100644 --- a/repoze/bfg/functional.py +++ b/repoze/bfg/functional.py @@ -94,10 +94,8 @@ def update_wrapper(wrapper, function (defaults to functools.WRAPPER_UPDATES) """ for attr in assigned: - try: - setattr(wrapper, attr, getattr(wrapped, attr)) - except TypeError: # Python 2.3 doesn't allow assigning to __name__. - pass + setattr(wrapper, attr, getattr(wrapped, attr)) + for attr in updated: getattr(wrapper, attr).update(getattr(wrapped, attr)) # Return the wrapper so this can be used as a decorator via curry() -- cgit v1.2.3