fixed issue with missing ref to mediator object