1. URL: https://object.local/?oseid=2052A62hlvOV6hlqej5yS2MwoYpUxXTtMQQb . When a certain condition is met, I want to remove the query parameter oseid so that the URL becomes https://object.local/ . I do not want to achieve this using a 302 redirect.
2. The specific implementation is as follows
PHP
var_dump($request->query('oseid'));
$request->query->remove('oseid');
var_dump($request->query('oseid'));
exit;
3. The printed result is as follows, which meets expectations. See Figure 1

Plaintext
string(36) "2052A62hlvOV6hlqej5yS2MwoYpUxXTtMQQb" NULL
