fixed inline error; works with updated api response