UNPKG

@wmfs/tymly

Version:

A framework for building and sharing workflows in Node.js

17 lines (14 loc) 415 B
module.exports = class DeleteCacheItem { init (resourceConfig, env) { this.caches = env.bootedServices.caches } run (event, context) { const { cacheName, key } = event try { this.caches.delete(cacheName, key) return context.sendTaskSuccess() } catch (err) { return context.sendTaskFailure({ error: 'DeleteCacheItemFail', cause: err }) } } // run } // DeleteCacheItem