"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.DefaultResolver = void 0;
const options_resolver_1 = require("../options-resolver");
/**
 * Default resolver
 */
class DefaultResolver {
    /**
     * Resolves if an account has to be set as default.
     * @param {CreateProfileOptions} options - Command options.
     * @param {string} altText - Alternative text.
     * @returns {Promise<boolean>}
     */
    async resolve(options, altText) {
        if (await (0, options_resolver_1.OptionsConfirmResolver)(options, 'default', altText ? altText : 'Do you want to set the account as the default profile?')) {
            options.default = true;
        }
        return options.default;
    }
}
exports.DefaultResolver = DefaultResolver;
