Add support for $currentISODate$ in trusted-set-cookie scriptlet

Related discussion:
https://github.com/uBlockOrigin/uAssets/discussions/20789#discussioncomment-9979107
This commit is contained in:
Raymond Hill 2024-07-07 11:18:20 -04:00
parent 37d31a82d8
commit a3576ea651
No known key found for this signature in database
GPG key ID: 25E1490B761470C2

View file

@ -4248,6 +4248,9 @@ function trustedSetCookie(
if ( value.includes('$currentDate$') ) {
value = value.replaceAll('$currentDate$', time.toUTCString());
}
if ( value.includes('$currentISODate$') ) {
value = value.replaceAll('$currentISODate$', time.toISOString());
}
let expires = '';
if ( offsetExpiresSec !== '' ) {