Changed flush_cache function access scope