@@ -37,7 +37,7 @@ export class UserService {
3737 try {
3838 user = await this . updateUser ( lowerUsername , githubToken ) ;
3939 } catch {
40- throw new HttpException ( `can't update this user.` , HttpStatus . SERVICE_UNAVAILABLE ) ;
40+ throw new HttpException ( `can't update user ${ lowerUsername } .` , HttpStatus . SERVICE_UNAVAILABLE ) ;
4141 }
4242 }
4343 const { totalRank, tierRank } =
@@ -82,11 +82,11 @@ export class UserService {
8282 const utc = updatedUser . scoreHistory [ updatedUser . scoreHistory . length - 1 ] . date . getTime ( ) ;
8383 if ( new Date ( utc + KR_TIME_DIFF ) . getDate ( ) === new Date ( ) . getDate ( ) ) {
8484 updatedUser . scoreHistory . pop ( ) ;
85- updatedUser . scoreHistory . push ( {
86- date : new Date ( ) ,
87- score : updatedUser . score ,
88- } ) ;
8985 }
86+ updatedUser . scoreHistory . push ( {
87+ date : new Date ( ) ,
88+ score : updatedUser . score ,
89+ } ) ;
9090 if ( updatedUser . scoreHistory . length > 1 ) {
9191 updatedUser . scoreDifference =
9292 updatedUser . score - updatedUser . scoreHistory [ updatedUser . scoreHistory . length - 2 ] . score ;
@@ -270,7 +270,7 @@ export class UserService {
270270 primaryLanguages : Array . from ( languagesScore . keys ( ) ) . slice ( 0 , 3 ) ,
271271 } ;
272272 } catch {
273- throw new HttpException ( `can't update this user.` , HttpStatus . SERVICE_UNAVAILABLE ) ;
273+ throw new HttpException ( `can't update user ${ lowerUsername } .` , HttpStatus . SERVICE_UNAVAILABLE ) ;
274274 }
275275 }
276276
0 commit comments