reorder make move logic to extra function