aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/Lib/urllib/request.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/urllib/request.py')
-rw-r--r--Lib/urllib/request.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/Lib/urllib/request.py b/Lib/urllib/request.py
index 9a3d399f018..df2ff06f0fc 100644
--- a/Lib/urllib/request.py
+++ b/Lib/urllib/request.py
@@ -426,8 +426,7 @@ class Request:
self.unredirected_hdrs.pop(header_name, None)
def header_items(self):
- hdrs = self.unredirected_hdrs.copy()
- hdrs.update(self.headers)
+ hdrs = {**self.unredirected_hdrs, **self.headers}
return list(hdrs.items())
class OpenerDirector: