Skip to content

Commit 9e43fe8

Browse files
authored
amend check of options.expires in cookie.js
1 parent ce23350 commit 9e43fe8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

6-data-storage/01-cookie/cookie.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ function setCookie(name, value, options = {}) {
1313
...options
1414
};
1515

16-
if (options.expires instanceof Date && options.expires.toUTCString) {
16+
if (options.expires instanceof Date) {
1717
options.expires = options.expires.toUTCString();
1818
}
1919

0 commit comments

Comments
 (0)