Explorar o código

Only consider bots for roles if they have the FEATURE_ROLES feature.

Issue #87
Bryan Drewery %!s(int64=10) %!d(string=hai) anos
pai
achega
371f9ee5df
Modificáronse 1 ficheiros con 4 adicións e 0 borrados
  1. 4 0
      src/mod/irc.mod/irc.cc

+ 4 - 0
src/mod/irc.mod/irc.cc

@@ -1785,6 +1785,10 @@ static void rebalance_roles_chan(struct chanset_t* chan)
     if (!chk_op(fr, chan)) {
       continue;
     }
+    /* Only consider bots that have the roles feature. */
+    if (!(m->user->fflags & FEATURE_ROLES)) {
+      continue;
+    }
     bots << m->user->handle;
   }
   botcount = bots.length();