reorder code again