notice: forgot some logs mb
This commit is contained in:
parent
5f58b65a34
commit
c4407adffb
@ -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) {
|
||||||
|
Loading…
Reference in New Issue
Block a user