fix cache flush and getCacheTag