@@ -6,19 +6,14 @@ import { DatabaseManager, PlatformNames } from '@togethercrew.dev/db';
66
77import config from '../config' ;
88import parentLogger from '../config/logger' ;
9- import { discord , generateCodeChallenge , generateCodeVerifier , generateState , google , twitter } from '../config/oAtuh2' ;
9+ import {
10+ discord , generateCodeChallenge , generateCodeVerifier , generateState , google , twitter
11+ } from '../config/oAtuh2' ;
1012import { IAuthAndPlatform , ISessionRequest } from '../interfaces' ;
1113import { IAuthRequest } from '../interfaces/Request.interface' ;
1214import {
13- discordServices ,
14- discourseService ,
15- githubService ,
16- googleService ,
17- notionService ,
18- platformService ,
19- tokenService ,
20- twitterService ,
21- userService ,
15+ discordServices , discourseService , githubService , googleService , notionService , platformService ,
16+ tokenService , twitterService , userService
2217} from '../services' ;
2318import { catchAsync , pick } from '../utils' ;
2419
@@ -323,7 +318,10 @@ const getPlatform = catchAsync(async function (req: IAuthRequest, res: Response)
323318 res . send ( platform ) ;
324319} ) ;
325320const updatePlatform = catchAsync ( async function ( req : IAuthAndPlatform , res : Response ) {
321+ console . log ( 'Debug1' ) ;
326322 platformService . validatePlatformUpdate ( req . platform , req . body ) ;
323+ console . log ( 'Debug2' ) ;
324+
327325 const platform = await platformService . updatePlatform ( req . platform , req . user , req . body ) ;
328326 res . send ( platform ) ;
329327} ) ;
0 commit comments