summary refs log tree commit diff
path: root/synapse/util/frozenutils.py
diff options
context:
space:
mode:
authorAndrew Morgan <andrew@amorgan.xyz>2020-08-03 16:15:34 -0700
committerAndrew Morgan <andrew@amorgan.xyz>2020-08-03 16:15:34 -0700
commit48e7f210c6655b83a2f719acb7f41cf0fece10a1 (patch)
tree961b66bdd6b432bc8af4f8519e4fce81bd2f4863 /synapse/util/frozenutils.py
parentMerge commit '98c4e35e3' into dinsic (diff)
parentReplace all remaining six usage with native Python 3 equivalents (#7704) (diff)
downloadsynapse-48e7f210c6655b83a2f719acb7f41cf0fece10a1.tar.xz
Merge commit 'a3f11567d' into dinsic
* commit 'a3f11567d':
  Replace all remaining six usage with native Python 3 equivalents (#7704)
Diffstat (limited to 'synapse/util/frozenutils.py')
-rw-r--r--synapse/util/frozenutils.py6
1 files changed, 2 insertions, 4 deletions
diff --git a/synapse/util/frozenutils.py b/synapse/util/frozenutils.py

index 9815bb8667..eab78dd256 100644 --- a/synapse/util/frozenutils.py +++ b/synapse/util/frozenutils.py
@@ -13,8 +13,6 @@ # See the License for the specific language governing permissions and # limitations under the License. -from six import binary_type, text_type - from canonicaljson import json from frozendict import frozendict @@ -26,7 +24,7 @@ def freeze(o): if isinstance(o, frozendict): return o - if isinstance(o, (binary_type, text_type)): + if isinstance(o, (bytes, str)): return o try: @@ -41,7 +39,7 @@ def unfreeze(o): if isinstance(o, (dict, frozendict)): return dict({k: unfreeze(v) for k, v in o.items()}) - if isinstance(o, (binary_type, text_type)): + if isinstance(o, (bytes, str)): return o try: