route type detection should be optional