chore: replace deprecated String.prototype.substr()
chore: replace deprecated String.prototype.substr()

.substr() is deprecated so we replace it with .slice() which works similarily but isn't deprecated
Signed-off-by: Tobias Speicher <0bf48b1b307ef620053f01d201166f9ed9f81d78@gmail.com>

peers/peerjs