(John J Lee)

Minor code clarification and simplification.
This commit is contained in:
Raymond Hettinger 2005-02-05 14:37:06 +00:00
parent bab4143348
commit f7bf02ded5
1 changed files with 6 additions and 3 deletions

View File

@ -304,10 +304,13 @@ class OpenerDirector:
self.handle_error[protocol] = lookup
elif condition == "open":
kind = protocol
lookup = getattr(self, "handle_"+condition)
elif condition in ["response", "request"]:
lookup = self.handle_open
elif condition == "response":
kind = protocol
lookup = getattr(self, "process_"+condition)
lookup = self.process_response
elif condition == "request":
kind = protocol
lookup = self.process_request
else:
continue