PeerJS not working on my project


I’ve recently deployed my app here on Glitch. However, I can’t seem to get the PeerJS or the part of it to work.

In my script.js I have this code

const myPeer = new Peer(undefined, {
    host: '',
    port: '3001'

and on my server.js I have

io.on('connection', socket => 
    socket.on('join-room', (roomId, userId) => {
        socket.join(roomId)'user-connected', userId)
        socket.on('disconnect', () =>{
  'user-disconnected', userId)

There should be a Client Connected/ Disconnected message whenever a user enters a room with the same parameter in the URL, but I’m not getting any on the Glitch terminal.

I would appreciate any help this can get. Thanks!

Assuming script.js is running on client side, try port 443 for HTTPS.
Which internal port is server.js serving to?

I never got peerjs working because of a firewall issue have any other peer to peer apps worked?