Fixed incorrect Rewrite rules