Using correct output data when serializing flash scope cookie