'Lookup a config field and return its value, first checking the
route.config, then route.app.config.'

def get_config(self, key, default=None):

    for conf in (self.config, self.app.config):
        if (key in conf):
            return conf[key]
    return default
