made Cookie stringification more robust