if (rup && (rup->status & QUSTAT_DEAD))
rup=NULL;
- if (rup && (rcup=findreguseronchannel(rcp,rup)) && CUKnown(rcup) && cp->users->totalusers >= 3)
+ if (rup && (rcup=findreguseronchannel(rcp,rup)) && CUHasOpPriv(rcup) && cp->users->totalusers >= 3)
rcp->lastactive=time(NULL);
/* Update last use time */
}
/* Check for other ban lurking on channel which we are enforcing */
- if (CIsEnforce(rcp) && nickbanned_visible(np,cp)) {
+ if (CIsEnforce(rcp) && nickbanned(np,cp,1)) {
localkickuser(chanservnick,cp,np,"Banned.");
return;
}
Error("chanserv",ERR_WARNING,"Found user on channel %s who doesn't exist!",cp->index->name->content);
continue;
}
- if (!IsService(np) && nickmatchban_visible(np,cbp)) {
+ if (!IsService(np) && nickmatchban(np,cbp,1)) {
localkickuser(chanservnick,cp,np,"Banned.");
}
}
return;
if (CIsForceTopic(rcp)) {
- if (rcp->topic) {
- /* Forced topic: change it back */
- localsettopic(chanservnick, cp, rcp->topic->content);
- }
+ /* Forced topic: change it back even if blank */
+ localsettopic(chanservnick, cp, (rcp->topic)?rcp->topic->content:"");
} else if (CIsTopicSave(rcp)) {
if (rcp->topic) {
freesstring(rcp->topic);