Multisession mode cleanup.

This commit is contained in:
Jonathan Piacenti 2015-02-26 23:39:13 -06:00 committed by Griatch
parent aac9ba7b8b
commit ba3bd91851
2 changed files with 3 additions and 2 deletions

View file

@ -110,7 +110,7 @@ class ServerSession(Session):
if self.logged_in:
sessid = self.sessid
player = self.player
player.unpuppet_object(sessid)
player.unpuppet_object(sessid, ignore_empty=True)
uaccount = player
uaccount.last_login = datetime.now()
uaccount.save()

View file

@ -456,7 +456,8 @@ class ServerSessionHandler(SessionHandler):
"""
sessions = make_iter(session)
text = text and to_str(to_unicode(text), encoding=sessions[0].encoding)
session = sessions[0]
text = text and to_str(to_unicode(text), encoding=session.encoding)
multi = not kwargs.pop("_nomulti", None)
forced_nomulti = kwargs.pop("_forced_nomulti", None)
# Mode 1 mirrors to all.