Replacing cache delete function with new object