Fixed a cookie related bug.