From 8583123385fcfb9aabd2a74fdaf4e5fb45ae3df5 Mon Sep 17 00:00:00 2001 From: Sviatoslav Sydorenko Date: Sun, 22 Apr 2018 05:15:30 +0200 Subject: Drop unneeded to_native_or_none --- cherrypy/lib/auth_digest.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/cherrypy/lib/auth_digest.py b/cherrypy/lib/auth_digest.py index ecd07f93..e3f1c762 100644 --- a/cherrypy/lib/auth_digest.py +++ b/cherrypy/lib/auth_digest.py @@ -143,13 +143,10 @@ def H(s): def _try_decode_map_values(param_map, charset): global FALLBACK_CHARSET - def to_native_or_none(v, enc): - return tonative(v, enc) if v is not None else v - for enc in (charset, FALLBACK_CHARSET): try: return { - k: to_native_or_none(v, enc) + k: tonative(v, enc) for k, v in param_map.items() } except ValueError as ve: -- cgit v1.2.1