mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-01 19:46:01 +01:00
fixing bug where the favourites star was still shaded in if an anon tried to favourite a post
This commit is contained in:
@@ -277,6 +277,11 @@ marked.setOptions({
|
||||
type: 'error',
|
||||
timeout: 5000
|
||||
});
|
||||
|
||||
socket.emit('api:posts.favourite', {
|
||||
status: 'error',
|
||||
pid: pid
|
||||
});
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -293,6 +298,10 @@ marked.setOptions({
|
||||
if (room_id) {
|
||||
io.sockets.in(room_id).emit('event:rep_up', {uid: uid !== uid_of_poster ? uid_of_poster : 0, pid: pid});
|
||||
}
|
||||
|
||||
socket.emit('api:posts.favourite', {
|
||||
status: 'ok'
|
||||
});
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user