Only remove query argument if configured