Fix remove when REWRITE_ARGS is true