var utils = require("./lib/utils")

;(function () {
    const col = context.collection()
    const collectionName = col && col.name ? col.name : null
    const req = context.request()
    const method = req.method
    const entryId = (context.data && !Array.isArray(context.data) && context.data.id) || req.param("id") || null

    utils.clearSSRCache(collectionName, entryId, method)
})()
