Преглед на файлове

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

Issue #87
Bryan Drewery преди 10 години
родител
ревизия
371f9ee5df
променени са 1 файла, в които са добавени 4 реда и са изтрити 0 реда
  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();