Do not give MpdDispatcher an MpdSession object yet, as it is not needed to get current tests passing

This commit is contained in:
Stein Magnus Jodal 2011-03-19 15:55:25 +01:00
parent 122e13be85
commit 49d62aecab
2 changed files with 2 additions and 4 deletions

View File

@ -24,9 +24,7 @@ class MpdDispatcher(object):
# XXX Consider merging MpdDispatcher into MpdSession
def __init__(self, session):
self.session = session
def __init__(self):
backend_refs = ActorRegistry.get_by_class(Backend)
assert len(backend_refs) == 1, 'Expected exactly one running backend.'
self.backend = backend_refs[0].proxy()

View File

@ -23,7 +23,7 @@ class MpdSession(asynchat.async_chat):
self.input_buffer = []
self.authenticated = False
self.set_terminator(LINE_TERMINATOR.encode(ENCODING))
self.dispatcher = MpdDispatcher(self)
self.dispatcher = MpdDispatcher()
def start(self):
"""Start a new client session."""