Fix cookieOptions plugin bug