Revert "Fix problem with trying to pass non-text to msg(text=...). Resolves #996."
This reverts commit 8fe631d808.
This commit is contained in:
parent
8fe631d808
commit
15036e8069
3 changed files with 3 additions and 5 deletions
|
|
@ -21,7 +21,7 @@ from evennia.commands.cmdsethandler import CmdSetHandler
|
||||||
from evennia.commands import cmdhandler
|
from evennia.commands import cmdhandler
|
||||||
from evennia.utils import logger
|
from evennia.utils import logger
|
||||||
from evennia.utils.utils import (variable_from_module, lazy_property,
|
from evennia.utils.utils import (variable_from_module, lazy_property,
|
||||||
make_iter, to_unicode, to_str)
|
make_iter, to_unicode)
|
||||||
|
|
||||||
_MULTISESSION_MODE = settings.MULTISESSION_MODE
|
_MULTISESSION_MODE = settings.MULTISESSION_MODE
|
||||||
|
|
||||||
|
|
@ -501,7 +501,6 @@ class DefaultObject(with_metaclass(TypeclassBase, ObjectDB)):
|
||||||
except Exception:
|
except Exception:
|
||||||
logger.log_trace()
|
logger.log_trace()
|
||||||
|
|
||||||
text = text if text is None else to_str(text, force_string=True)
|
|
||||||
kwargs["options"] = options
|
kwargs["options"] = options
|
||||||
|
|
||||||
# relay to session(s)
|
# relay to session(s)
|
||||||
|
|
|
||||||
|
|
@ -416,7 +416,6 @@ class DefaultPlayer(with_metaclass(TypeclassBase, PlayerDB)):
|
||||||
except Exception:
|
except Exception:
|
||||||
pass
|
pass
|
||||||
|
|
||||||
text = text if text is None else to_str(text, force_string=True)
|
|
||||||
kwargs["options"] = options
|
kwargs["options"] = options
|
||||||
|
|
||||||
# session relay
|
# session relay
|
||||||
|
|
|
||||||
|
|
@ -16,7 +16,7 @@ from django.utils import timezone
|
||||||
from django.conf import settings
|
from django.conf import settings
|
||||||
from evennia.comms.models import ChannelDB
|
from evennia.comms.models import ChannelDB
|
||||||
from evennia.utils import logger
|
from evennia.utils import logger
|
||||||
from evennia.utils.utils import make_iter, lazy_property, to_str
|
from evennia.utils.utils import make_iter, lazy_property
|
||||||
from evennia.commands.cmdsethandler import CmdSetHandler
|
from evennia.commands.cmdsethandler import CmdSetHandler
|
||||||
from evennia.server.session import Session
|
from evennia.server.session import Session
|
||||||
|
|
||||||
|
|
@ -392,7 +392,7 @@ class ServerSession(Session):
|
||||||
# that auto-adds the session, we'd get a kwarg collision.
|
# that auto-adds the session, we'd get a kwarg collision.
|
||||||
kwargs.pop("session", None)
|
kwargs.pop("session", None)
|
||||||
if text is not None:
|
if text is not None:
|
||||||
self.data_out(text=to_str(text, force_string=True), **kwargs)
|
self.data_out(text=text, **kwargs)
|
||||||
else:
|
else:
|
||||||
self.data_out(**kwargs)
|
self.data_out(**kwargs)
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue