Skip to content

Commit d288018

Browse files
committed
wiring all new implementations into authkit module
1 parent 2167a1c commit d288018

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/auth-kit.module.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,8 @@ import { PermissionRepository } from '@repos/permission.repository';
2626
import { AuthenticateGuard } from '@middleware/authenticate.guard';
2727
import { AdminGuard } from '@middleware/admin.guard';
2828
import { AdminRoleService } from '@services/admin-role.service';
29+
import { OAuthService } from '@services/oauth.service';
30+
import passport from 'passport';
2931

3032
@Module({
3133
imports: [
@@ -54,6 +56,7 @@ import { AdminRoleService } from '@services/admin-role.service';
5456
AuthenticateGuard,
5557
AdminGuard,
5658
AdminRoleService,
59+
OAuthService,
5760
],
5861
exports: [
5962
AuthService,
@@ -72,7 +75,7 @@ import { AdminRoleService } from '@services/admin-role.service';
7275
export class AuthKitModule implements NestModule {
7376
configure(consumer: MiddlewareConsumer) {
7477
consumer
75-
.apply(cookieParser())
78+
.apply(cookieParser(), passport.initialize())
7679
.forRoutes({ path: '*', method: RequestMethod.ALL });
7780
}
7881
}

0 commit comments

Comments
 (0)