Handle Rook reference class case for 'onHeaders'.