File tree Expand file tree Collapse file tree 2 files changed +3
-8
lines changed Expand file tree Collapse file tree 2 files changed +3
-8
lines changed Original file line number Diff line number Diff line change @@ -395,16 +395,13 @@ const RoomsContainer = () => {
395
395
</ Typography >
396
396
{ userJoined ? (
397
397
< >
398
- < Typography
399
- variant = "h6"
400
- color = { userColors [ userList . indexOf ( userName ) ] }
401
- >
398
+ < Typography variant = "h6" color = "#898a8b" >
402
399
Nickname: { userName }
403
400
</ Typography >
404
401
< Typography
405
402
variant = "body1"
406
403
sx = { {
407
- color : 'white '
404
+ color : '#898a8b '
408
405
} }
409
406
>
410
407
Users: { userList . length }
@@ -415,11 +412,9 @@ const RoomsContainer = () => {
415
412
height : 300 ,
416
413
maxWidth : 200 ,
417
414
bgcolor : '#333333' ,
418
- border : '3px solid #f2fbf8' ,
419
415
borderRadius : '5%' ,
420
416
display : 'flex' ,
421
417
flexDirection : 'column' ,
422
- alignItems : 'center' ,
423
418
overflow : 'auto' ,
424
419
color : 'white'
425
420
} }
Original file line number Diff line number Diff line change @@ -190,7 +190,7 @@ io.on('connection', (client) => {
190
190
//disconnecting functionality
191
191
client . on ( 'disconnecting' , ( ) => {
192
192
const roomCode = Array . from ( client . rooms ) [ 1 ] ; //grabbing current room client was in when disconnecting
193
- const userName = roomLists [ roomCode ] [ client . id ] ;
193
+ const userName = roomLists [ roomCode ] [ client . id ] . userName ;
194
194
delete roomLists [ roomCode ] [ client . id ] ;
195
195
//if room empty, delete room from room list
196
196
if ( ! Object . keys ( roomLists [ roomCode ] ) . length ) {
You can’t perform that action at this time.
0 commit comments