"use strict";
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
    var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
    if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
    else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
    return c > 3 && r && Object.defineProperty(target, key, r), r;
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.AuthModule = void 0;
const common_1 = require("@nestjs/common");
const typeorm_1 = require("@nestjs/typeorm");
const passport_1 = require("@nestjs/passport");
const auth_controller_1 = require("./auth.controller");
const auth_service_1 = require("./auth.service");
const jwt_strategy_1 = require("./strategies/jwt.strategy");
const google_strategy_1 = require("./strategies/google.strategy");
const roles_guard_1 = require("./guards/roles.guard");
const user_entity_1 = require("./entities/user.entity");
const role_entity_1 = require("./entities/role.entity");
const user_profile_entity_1 = require("./entities/user-profile.entity");
const refresh_token_entity_1 = require("./entities/refresh-token.entity");
const user_verification_entity_1 = require("./entities/user-verification.entity");
const permission_entity_1 = require("./entities/permission.entity");
const role_permission_entity_1 = require("./entities/role-permission.entity");
const cleanup_service_1 = require("../common/services/cleanup.service");
const permissions_guard_1 = require("./guards/permissions.guard");
const permissions_service_1 = require("./services/permissions.service");
let AuthModule = class AuthModule {
};
exports.AuthModule = AuthModule;
exports.AuthModule = AuthModule = __decorate([
    (0, common_1.Global)(),
    (0, common_1.Module)({
        imports: [
            typeorm_1.TypeOrmModule.forFeature([user_entity_1.User, role_entity_1.Role, user_profile_entity_1.UserProfile, refresh_token_entity_1.RefreshToken, user_verification_entity_1.UserVerification, permission_entity_1.Permission, role_permission_entity_1.RolePermission]),
            passport_1.PassportModule,
        ],
        controllers: [auth_controller_1.AuthController],
        providers: [auth_service_1.AuthService, jwt_strategy_1.JwtStrategy, google_strategy_1.GoogleStrategy, roles_guard_1.RolesGuard, permissions_guard_1.PermissionsGuard, permissions_service_1.PermissionsService, cleanup_service_1.CleanupService],
        exports: [roles_guard_1.RolesGuard, permissions_guard_1.PermissionsGuard, permissions_service_1.PermissionsService],
    })
], AuthModule);
//# sourceMappingURL=auth.module.js.map