rework code for next step