WorldLanguages/ScratchNotifier.cf

ANNOYING BUG : It sends way too much notifications

Closed this issue · 9 comments

I had 1 unread message, it sent approximately 15 notifications at the same time!
way too much notifications screenshot
Firefox 65.0, macOS 10.11.6 El Capitan

Wow that's weird!
I don't know what is causing it tho, take a look at this line: https://github.com/WorldLanguages/ScratchNotifier/blob/master/notifier.js#L115
It only sends the notification if msgCount > oldMsgCount, and oldMsgCount is the value of the global variable msgCount before checking the message count again.
Unless Firefox for some reason decided to trigger checkMainMessages() many times at once for some reason, I have no idea what can cause this.

It didn't did after. My computer was sleeping, maybe it has impacted it ?

@locness3 That's probably it. I'll make a fix soon.

This should be fixed with commit e66cfc1
checkMainMessages() now can only run if it hasn't been called in the last 5 seconds (and if that call was ran too).
@locness3 Would be helpful if you told me if this happens with alt accounts too. I don't know why it wouldn't, tho.

Huh, none of my alt accounts recieves messaages, lol

@locness3 Fixed, stupid bug because of something I modified the day of the release... Make sure to have the bell enabled for that alt of course, if you want to test this

You should unassign you so