mirror of
https://github.com/wxWidgets/Phoenix.git
synced 2026-01-07 20:40:11 +01:00
Replaced unicode() with six.text_type() for Python 3 compatibility.
This commit is contained in:
@@ -28,6 +28,7 @@
|
||||
This module contains the definitions of `PersistentObject` and `PersistenceManager` objects.
|
||||
"""
|
||||
|
||||
import six
|
||||
import wx
|
||||
import os
|
||||
import warnings
|
||||
@@ -783,10 +784,10 @@ class PersistenceManager(object):
|
||||
kind = repr(value.__class__).split("'")[1]
|
||||
|
||||
if self._customConfigHandler is not None:
|
||||
result = self._customConfigHandler.SaveValue(self.GetKey(obj, keyName), repr((kind, unicode(value))))
|
||||
result = self._customConfigHandler.SaveValue(self.GetKey(obj, keyName), repr((kind, six.text_type(value))))
|
||||
else:
|
||||
config = self.GetPersistenceFile()
|
||||
result = config.Write(self.GetKey(obj, keyName), repr((kind, unicode(value))))
|
||||
result = config.Write(self.GetKey(obj, keyName), repr((kind, six.text_type(value))))
|
||||
config.Flush()
|
||||
|
||||
return result
|
||||
|
||||
Reference in New Issue
Block a user