change protocol logic