From f1cea6a6fa7578b06ca4a8a446308b4597a71575 Mon Sep 17 00:00:00 2001 From: Johannes Gijsbers Date: Sun, 9 Jan 2005 05:53:27 +0000 Subject: Backport patch #1095362: replace hardcoded test for POST/GET with call to get_method, removing some duplication and gaining some flexibility in the process. --- Lib/urllib2.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Lib/urllib2.py b/Lib/urllib2.py index 644b380..3c777cd 100644 --- a/Lib/urllib2.py +++ b/Lib/urllib2.py @@ -856,7 +856,7 @@ class AbstractDigestAuthHandler: entdig = None A1 = "%s:%s:%s" % (user, realm, pw) - A2 = "%s:%s" % (req.has_data() and 'POST' or 'GET', + A2 = "%s:%s" % (req.get_method(), # XXX selector: what about proxies and full urls req.get_selector()) if qop == 'auth': -- cgit v0.12