Make routing code a lot cleaner and less repetitive