"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports._migrateLinkUnderlinesCapability = _migrateLinkUnderlinesCapability;
const get_prop_1 = require("../../objects/get-prop");
const util_1 = require("../../util");
/**
 * Remove underlinedLinks capability from site model
 * @private
 * @param {object} model Site Model
 * @returns {object}
 */
function _migrateLinkUnderlinesCapability(model) {
    // apply migration
    const clone = (0, util_1.cloneObject)(model);
    const capabilities = (0, get_prop_1.getProp)(model, "data.values.capabilities");
    if (capabilities) {
        // migrate capabilities - remove underlinedLinks
        clone.data.values.capabilities = capabilities.filter((capability) => capability !== "underlinedLinks");
    }
    return clone;
}
//# sourceMappingURL=_migrate-link-underlines-capability.js.map