"use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.metadata=void 0;const query_1=require("@b/utils/query");exports.metadata={summary:"Deletes a specific tag",operationId:"deleteTag",tags:["Admin","Content","Tag"],parameters:(0,query_1.deleteRecordParams)("Tag"),responses:(0,query_1.deleteRecordResponses)("Tag"),permission:"delete.blog.tag",requiresAuth:!0,logModule:"ADMIN_BLOG",logTitle:"Delete tag"};exports.default=async e=>{const{params:t,query:s,ctx:a}=e;null==a||a.step("Validating tag ID");null==a||a.step("Deleting tag");const l=await(0,query_1.handleSingleDelete)({model:"tag",id:t.id,query:s});null==a||a.success("Tag deleted successfully");return l};