Patchwork D7535: win32mbcs: fix a `str` type conditional for py3

login
register
mail settings
Submitter phabricator
Date Dec. 2, 2019, 9:55 p.m.
Message ID <b7e79b45468d4ea2a04291a1b1cebd56@localhost.localdomain>
Download mbox | patch
Permalink /patch/43570/
State Not Applicable
Headers show

Comments

phabricator - Dec. 2, 2019, 9:55 p.m.
Closed by commit rHG66210a20f727: win32mbcs: fix a `str` type conditional for py3 (authored by mharbison72).
This revision was automatically updated to reflect the committed changes.

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D7535?vs=18411&id=18428

CHANGES SINCE LAST ACTION
  https://phab.mercurial-scm.org/D7535/new/

REVISION DETAIL
  https://phab.mercurial-scm.org/D7535

AFFECTED FILES
  hgext/win32mbcs.py

CHANGE DETAILS




To: mharbison72, #hg-reviewers, dlax, pulkit
Cc: mercurial-devel

Patch

diff --git a/hgext/win32mbcs.py b/hgext/win32mbcs.py
--- a/hgext/win32mbcs.py
+++ b/hgext/win32mbcs.py
@@ -77,7 +77,7 @@ 
 
 
 def decode(arg):
-    if isinstance(arg, str):
+    if isinstance(arg, bytes):
         uarg = arg.decode(_encoding)
         if arg == uarg.encode(_encoding):
             return uarg