notice: forgot some logs mb

This commit is contained in:
AdrienLSH 2024-04-25 15:48:26 +02:00
parent 5f58b65a34
commit c4407adffb

View File

@ -23,7 +23,6 @@ export default class Notice {
this._socket.onclose = _ => this._socket = undefined; this._socket.onclose = _ => this._socket = undefined;
this._socket.onmessage = message => { this._socket.onmessage = message => {
const data = JSON.parse(message.data); const data = JSON.parse(message.data);
console.log(data)
if (data.type === 'friend_request') { if (data.type === 'friend_request') {
this.friend_request(data.author); this.friend_request(data.author);
@ -45,7 +44,6 @@ export default class Notice {
} }
friend_request(author) { friend_request(author) {
console.log('hey')
client.me.incomingFriendRequests.push(new Profile(author.username, author.id, author.avatar)); client.me.incomingFriendRequests.push(new Profile(author.username, author.id, author.avatar));
createNotification('Friend Request', `<strong>${author.username}</strong> sent you a friend request.`); createNotification('Friend Request', `<strong>${author.username}</strong> sent you a friend request.`);
if (lastView instanceof ProfilePageView && lastView.profile.id === author.id) { if (lastView instanceof ProfilePageView && lastView.profile.id === author.id) {