style: shouldn't it be one line "fun(ClientRef) -> ..."?