ecrs-auth-core 1.0.28 → 1.0.29

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -80,23 +80,27 @@ exports.AUTH_CORE_OPTIONS = 'AUTH_CORE_OPTIONS';
80
80
  // }
81
81
  let AuthCoreModule = AuthCoreModule_1 = class AuthCoreModule {
82
82
  static registerAsync(options) {
83
- const asyncProvider = {
83
+ const authCoreOptionsProvider = {
84
84
  provide: exports.AUTH_CORE_OPTIONS,
85
85
  inject: options.inject,
86
86
  useFactory: options.useFactory,
87
87
  };
88
- const jwtModule = jwt_1.JwtModule.registerAsync({
88
+ const asyncJwtModule = jwt_1.JwtModule.registerAsync({
89
89
  inject: [exports.AUTH_CORE_OPTIONS],
90
- useFactory: async (options) => ({
91
- secret: options.jwtSecret,
92
- signOptions: { expiresIn: options.jwtExpiresIn },
93
- }),
90
+ useFactory: async (options) => {
91
+ console.log('✅ JWT_SECRET:', options.jwtSecret);
92
+ console.log('✅ JWT_EXPIRES_IN:', options.jwtExpiresIn);
93
+ return {
94
+ secret: options.jwtSecret,
95
+ signOptions: { expiresIn: options.jwtExpiresIn },
96
+ };
97
+ },
94
98
  });
95
99
  return {
96
100
  module: AuthCoreModule_1,
97
- imports: [jwtModule],
101
+ imports: [asyncJwtModule],
98
102
  providers: [
99
- asyncProvider,
103
+ authCoreOptionsProvider,
100
104
  {
101
105
  provide: 'MODULE_CONFIG',
102
106
  useFactory: (options) => options.moduleConfig || {},
@@ -113,7 +117,7 @@ let AuthCoreModule = AuthCoreModule_1 = class AuthCoreModule {
113
117
  ],
114
118
  controllers: [auth_controller_1.AuthController],
115
119
  exports: [
116
- jwt_1.JwtModule, // ✅ Export the configured JwtModule
120
+ jwt_1.JwtModule,
117
121
  auth_service_1.AuthService,
118
122
  jwt_strategy_1.JwtStrategy,
119
123
  jwt_guard_1.JwtAuthGuard,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ecrs-auth-core",
3
- "version": "1.0.28",
3
+ "version": "1.0.29",
4
4
  "description": "Centralized authentication and authorization module for ECRS apps",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",