def route_file(cfg, url, data):
    path = os.path.join(cfg['datadir'], data['path'].lstrip('/'))
    ext = tools.what_ext(cfg['extensions'].keys(), path)
    if ext:
        data.update({
            'root_datadir': path + '.' + ext,
            'bl_type': 'entry'
        })
        return data