Fix Miss code rewrite