change in logic order