fix context leakage