small code clean and ordering