Fixed bug that the cookie doesn't store and restore when there is no
cache folder