Corey rewrite