Changing the order of logic