Skip to content

Commit

Permalink
Update benchmark/diagnostics_channel/publish.js
Browse files Browse the repository at this point in the history
Co-authored-by: Almeida <[email protected]>
  • Loading branch information
RafaelGSS and almeidx authored Sep 3, 2024
1 parent 13eff4a commit 33ca0dc
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions benchmark/diagnostics_channel/publish.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,7 @@ function main({ n, subscribers, checkSubscribers, objSize }) {

bench.start();
for (let i = 0; i < n; i++) {
if (checkSubscribers) {
if (channel.hasSubscribers) {
channel.publish(data);
}
} else {
if (!checkSubscribers || channel.hasSubscribers) {
channel.publish(data);
}
}
Expand Down

0 comments on commit 33ca0dc

Please sign in to comment.