fix: wrong cause and removed flag in cookie change listener (#49103)

This commit is contained in:
Mr.Chaofan
2026-02-03 01:19:35 -08:00
committed by GitHub
parent 3776731f4a
commit 4413a0f642
4 changed files with 33 additions and 4 deletions

View File

@@ -51,7 +51,12 @@ Returns:
* `event` Event
* `cookie` [Cookie](structures/cookie.md) - The cookie that was changed.
* `cause` string - The cause of the change with one of the following values:
* `explicit` - The cookie was changed directly by a consumer's action.
* `inserted` - The cookie was inserted.
* `inserted-no-change-overwrite` - The newly inserted cookie overwrote a cookie but
did not result in any change. For example, inserting an identical cookie will produce this cause.
* `inserted-no-value-change-overwrite` - The newly inserted cookie overwrote a cookie but
did not result in any value change, but it's web observable (e.g. updates the expiry).
* `explicit` - The cookie was deleted directly by a consumer's action.
* `overwrite` - The cookie was automatically removed due to an insert
operation that overwrote it.
* `expired` - The cookie was automatically removed as it expired.