Found bugs in cache implementation - Fixed