Fixed bug with listeners not being removed properly after mediator unregister.