fix cookie bug in rails SDK