add atomic state change method for user.go