Improve BanEntry
[clinton/bobotpp.git] / source / UserCommands.C
index 457ebf5..0ad6ba7 100644 (file)
@@ -330,9 +330,9 @@ UserCommands::BanList(ServerConnection *cnx, Person *from,
   for (std::vector<BanEntry *>::iterator it = c->channelBanlist.begin();
        it != c->channelBanlist.end(); ++it)
     if ((*it)->getExpirationDate() == -1)
-      from->sendNotice((*it)->getMask().pad(30) + " -1");
+      from->sendNotice((*it)->getMask().getMask().pad(30) + " -1");
     else
-      from->sendNotice((*it)->getMask().pad(30) + " " + 
+      from->sendNotice((*it)->getMask().getMask().pad(30) + " " + 
                        String((long)((*it)->getExpirationDate()-current)));
   from->sendNotice("\002End of banlist.\002");
 }
@@ -1400,8 +1400,8 @@ UserCommands::TBan(ServerConnection *cnx, Person *from,
 
   for (std::vector<BanEntry *>::iterator it = c->channelBanlist.begin();
        it != c->channelBanlist.end(); ++it)
-    if (m.matches((*it)->banMask))
-      cnx->queue->sendChannelMode(channel, "-b", (*it)->banMask.getMask());
+    if (m.matches((*it)->getMask()))
+      cnx->queue->sendChannelMode(channel, "-b", (*it)->getMask().getMask());
 
   cnx->bot->channelList->getChannel(channel)->addBan(dest, w);
   cnx->queue->sendChannelMode(channel, "+b", dest);