Sort out orders formatting