"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.SocialNetworkProvidersValidator = void 0;
const express_validator_1 = require("express-validator");
const validator_handle_1 = require("../../utils/handlers/validator.handle");
const abstract_validator_1 = require("../abstract.validator");
class SocialNetworkProvidersValidator extends abstract_validator_1.AbstractValidator {
    constructor() {
        super();
    }
    createItem() {
        return [
            (0, express_validator_1.check)("name").exists().isString(),
            (0, express_validator_1.check)("cover").exists().isString(),
            (0, express_validator_1.check)("description").exists().isString(),
            (0, express_validator_1.check)("template").exists().isString(),
            (req, res, next) => {
                (0, validator_handle_1.validateResult)(req, res, next);
            },
        ];
    }
    updateItem() {
        return [
            (0, express_validator_1.check)("_id").exists().isMongoId(),
            (0, express_validator_1.check)("name").exists().isString(),
            (0, express_validator_1.check)("cover").exists().isString(),
            (0, express_validator_1.check)("description").exists().isString(),
            (0, express_validator_1.check)("template").exists().isString(),
            (req, res, next) => {
                (0, validator_handle_1.validateResult)(req, res, next);
            },
        ];
    }
}
exports.SocialNetworkProvidersValidator = SocialNetworkProvidersValidator;
