before delete state
tiding