Code clean-up and simplifying routes