mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-10-26 18:09:45 +00:00
LibWeb: Implement CookieStore::get(name)
This commit is contained in:
parent
dc1b7b1925
commit
5545d38d7a
Notes:
github-actions[bot]
2025-08-08 17:12:25 +00:00
Author: https://github.com/IdanHo
Commit: 5545d38d7a
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/5766
Reviewed-by: https://github.com/trflynn89 ✅
14 changed files with 174 additions and 17 deletions
|
|
@ -2148,7 +2148,7 @@ Messages::WebDriverClient::GetAllCookiesResponse WebDriverConnection::get_all_co
|
|||
// 4. For each cookie in all associated cookies of the current browsing context’s active document:
|
||||
auto* document = current_browsing_context().active_document();
|
||||
|
||||
for (auto const& cookie : current_browsing_context().page().client().page_did_request_all_cookies(document->url())) {
|
||||
for (auto const& cookie : current_browsing_context().page().client().page_did_request_all_cookies_webdriver(document->url())) {
|
||||
// 1. Let serialized cookie be the result of serializing cookie.
|
||||
auto serialized_cookie = serialize_cookie(cookie);
|
||||
|
||||
|
|
@ -3070,7 +3070,7 @@ void WebDriverConnection::delete_cookies(Optional<StringView> const& name)
|
|||
// For each cookie among all associated cookies of the current browsing context’s active document, un the substeps of the first matching condition:
|
||||
auto* document = current_browsing_context().active_document();
|
||||
|
||||
for (auto& cookie : current_browsing_context().page().client().page_did_request_all_cookies(document->url())) {
|
||||
for (auto& cookie : current_browsing_context().page().client().page_did_request_all_cookies_webdriver(document->url())) {
|
||||
// -> name is undefined
|
||||
// -> name is equal to cookie name
|
||||
if (!name.has_value() || name.value() == cookie.name) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue