tweak cookie method.