fix a minor bug in the example

This commit is contained in:
TomSssM 2019-10-28 20:23:29 +03:00
parent 4159a65ea2
commit 83cdcedf81

View file

@ -310,7 +310,7 @@ function setCookie(name, value, options = {}) {
...options ...options
}; };
if (options.expires.toUTCString) { if (options.expires && options.expires.toUTCString) {
options.expires = options.expires.toUTCString(); options.expires = options.expires.toUTCString();
} }