@@ -162,7 +162,11 @@ export default class DesignReviewsService {
162162 for ( const memberUserSetting of memberUserSettings ) {
163163 if ( memberUserSetting . slackId ) {
164164 try {
165- await sendSlackDesignReviewNotification ( memberUserSetting . slackId , designReview . designReviewId ) ;
165+ await sendSlackDesignReviewNotification (
166+ memberUserSetting . slackId ,
167+ designReview . designReviewId ,
168+ designReview . wbsElement . name
169+ ) ;
166170 } catch ( err : unknown ) {
167171 if ( err instanceof Error ) {
168172 throw new HttpException ( 500 , `Failed to send slack notification: ${ err . message } ` ) ;
@@ -321,19 +325,22 @@ export default class DesignReviewsService {
321325 if ( ! isUserOnDesignReview ( submitter , designReviewTransformer ( designReview ) ) )
322326 throw new HttpException ( 400 , 'Current user is not in the list of this design reviews members' ) ;
323327
324- // Update user schedule settings
325- const validAvailability = validateMeetingTimes ( availability ) ;
328+ availability . forEach ( ( time ) => {
329+ if ( time < 0 || time > 83 ) {
330+ throw new HttpException ( 400 , 'Availability times have to be in range 0-83' ) ;
331+ }
332+ } ) ;
326333
327334 await prisma . schedule_Settings . upsert ( {
328335 where : { userId : submitter . userId } ,
329336 update : {
330- availability : validAvailability
337+ availability
331338 } ,
332339 create : {
333340 userId : submitter . userId ,
334341 personalGmail : '' ,
335342 personalZoomLink : '' ,
336- availability : validAvailability
343+ availability
337344 }
338345 } ) ;
339346
@@ -353,7 +360,7 @@ export default class DesignReviewsService {
353360
354361 // If all requested attendees have confirmed their schedule, mark design review as confirmed
355362 if (
356- designReview . confirmedMembers . length ===
363+ updatedDesignReview . confirmedMembers . length ===
357364 designReview . requiredMembers . length + designReview . optionalMembers . length
358365 ) {
359366 await prisma . design_Review . update ( {
0 commit comments