Changed the logic to empty the cache from admin