Skip to content

Commit

Permalink
fix: pass in an array
Browse files Browse the repository at this point in the history
  • Loading branch information
oplik0 committed Aug 26, 2023
1 parent edf5a8c commit f7b0d06
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion static/lib/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ define('plugins/dice/main', [
socket.on('plugins:dice:event:new_roll', (data) => {
if (Array.isArray(data) && data.length && data.some(e => e.type === 'dice')) {
for (const event of data) {
hooks.one('action:posts.loaded', () => posts.addTopicEvents(event));
hooks.one('action:posts.loaded', () => posts.addTopicEvents([event]));
}
}
});
Expand Down

0 comments on commit f7b0d06

Please sign in to comment.