update userstate