Refactor ActorRef