Browse Source

fix(nocodb): remove acl for refresh token endpoint

Signed-off-by: Pranav C <pranavxc@gmail.com>
pull/5066/head
Pranav C 2 years ago
parent
commit
127b5b0535
  1. 12
      packages/nocodb/src/lib/meta/api/userApi/userApis.ts

12
packages/nocodb/src/lib/meta/api/userApi/userApis.ts

@ -533,7 +533,7 @@ const mapRoutes = (router) => {
'/user/password/change', '/user/password/change',
ncMetaAclMw(passwordChange, 'passwordChange') ncMetaAclMw(passwordChange, 'passwordChange')
); );
router.post('/auth/token/refresh', ncMetaAclMw(refreshToken, 'refreshToken')); router.post('/auth/token/refresh', catchError(refreshToken));
/* Google auth apis */ /* Google auth apis */
@ -572,10 +572,7 @@ const mapRoutes = (router) => {
'/api/v1/db/auth/password/change', '/api/v1/db/auth/password/change',
ncMetaAclMw(passwordChange, 'passwordChange') ncMetaAclMw(passwordChange, 'passwordChange')
); );
router.post( router.post('/api/v1/db/auth/token/refresh', catchError(refreshToken));
'/api/v1/db/auth/token/refresh',
ncMetaAclMw(refreshToken, 'refreshToken')
);
router.get( router.get(
'/api/v1/db/auth/password/reset/:tokenId', '/api/v1/db/auth/password/reset/:tokenId',
catchError(renderPasswordReset) catchError(renderPasswordReset)
@ -606,10 +603,7 @@ const mapRoutes = (router) => {
'/api/v1/auth/password/change', '/api/v1/auth/password/change',
ncMetaAclMw(passwordChange, 'passwordChange') ncMetaAclMw(passwordChange, 'passwordChange')
); );
router.post( router.post('/api/v1/auth/token/refresh', catchError(refreshToken));
'/api/v1/auth/token/refresh',
ncMetaAclMw(refreshToken, 'refreshToken')
);
// respond with password reset page // respond with password reset page
router.get('/auth/password/reset/:tokenId', catchError(renderPasswordReset)); router.get('/auth/password/reset/:tokenId', catchError(renderPasswordReset));
}; };

Loading…
Cancel
Save