def session_from_player(self, player, sessid):
        """
        Given a player and a session id, return the actual session
        object.

        Args:
            player (Player): The Player to get the Session from.
            sessid (int or list): Session id(s).

        Returns:
            sessions (Session or list): Session(s) found.

        """
        sessions = [self[sid] for sid in make_iter(sessid)
                    if self in sid and self[sid].logged_in and player.uid == self[sid].uid]
        return sessions[0] if len(sessions) == 1 else sessions
dataset/ETHPy150Open evennia/evennia/evennia/server/sessionhandler.py/ServerSessionHandler.session_from_player/swapped operands of `in`