FWIW I saw a more complex patch for this issue posted here
https://lab.louiz.org/louiz/biboumi/-/commit/0061298dd0945f7f67e7fa340c6649b179c804d5 from the Biboumi XMPP muc. I added the patch to 9.0-4 and compiled it for bullseye, and it seems to work. I tried connecting to oftc.net and tried using the ad-hoc commands to try to configure some irc settings.