refactoring -> cacheBlock()