bugs in cacheapi fixed