charybdis-ircd / charybdis

Scalable IRCv3.2 server for large, community-oriented networks
GNU General Public License v2.0
231 stars 102 forks source link

Deferred capability notifications from modules #276

Closed edk0 closed 5 years ago

edk0 commented 5 years ago

Reloading modules sends CAP DEL followed by an immediate CAP NEW:

:staberinde.local CAP * DEL :account-tag
:staberinde.local CAP * NEW :account-tag

This isn't very nice. /modrestart is particularly bad. In order to avoid doing this, we remember the capability set at the beginning of module operations, compare that with the set afterwards, and report only the differences with CAP {DEL,NEW}.