Fix the async sounds listener

This commit is contained in:
libraryaddict 2014-07-28 17:05:29 +12:00
parent a06a81182e
commit 6e3f5c1606

View File

@ -1066,8 +1066,10 @@ public class PacketsManager {
if (soundsListenerEnabled) {
asyncSoundsListener = ProtocolLibrary.getProtocolManager().getAsynchronousManager()
.registerAsyncHandler(soundsListener);
asyncSoundsListener.syncStart();
} else {
ProtocolLibrary.getProtocolManager().getAsynchronousManager().unregisterAsyncHandler(asyncSoundsListener);
asyncSoundsListener.syncStop();
}
}
}