UNPKG

couchbase-index-manager

Version:
23 lines 848 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.DropIndexMutation = void 0; const tslib_1 = require("tslib"); const chalk_1 = tslib_1.__importDefault(require("chalk")); const index_mutation_1 = require("./index-mutation"); /** * Represents an index mutation which drops an existing index */ class DropIndexMutation extends index_mutation_1.IndexMutation { print(logger) { logger.info(chalk_1.default.redBright(`Delete: ${this.displayName}`)); } async execute(indexManager, logger) { logger.info(chalk_1.default.redBright(`Deleting ${this.displayName}...`)); await indexManager.dropIndex(this.name, this.scope, this.collection); } isSafe() { return false; } } exports.DropIndexMutation = DropIndexMutation; //# sourceMappingURL=drop-index-mutation.js.map