delete method
Delete cookies for specified uri
.
This API will delete all cookies for the uri.host
, it will ignored the uri.path
.
withDomainSharedCookie
true
will delete the domain-shared cookies.
Implementation
@override
Future<void> delete(Uri uri, [bool withDomainSharedCookie = false]) async {
final host = uri.host;
hostCookies.remove(host);
if (withDomainSharedCookie) {
domainCookies.removeWhere(
(domain, v) => _isDomainMatch(uri.host, domain),
);
}
}