Skip to content

Commit 9223e92

Browse files
committed
adding buffer types for force_text
1 parent bd0e4ab commit 9223e92

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

wolframclient/utils/encoding.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,9 @@
66

77
force_text = Dispatch()
88

9+
@force_text.dispatch(six.buffer_types)
10+
def encode(s, *args, **opts):
11+
return force_text(force_bytes(s, *args, **opts), *args, **opts)
912

1013
@force_text.dispatch(six.text_type)
1114
def encode(s, encoding="utf-8", errors="strict"):

0 commit comments

Comments
 (0)