Rename to rewrite-url, refactor