fix bugs in the output of cache.json