Fixed error in the CookieEncoder