mirror of
https://github.com/unrealircd/unrealircd.git
synced 2026-07-04 01:23:13 +02:00
Replace various 90% identical functions with some macro's instead.
This commit is contained in:
@@ -71,8 +71,10 @@ int nonickchange_check (aClient *sptr, aChannel *chptr)
|
||||
{
|
||||
if (!IsOper(sptr) && !IsULine(sptr)
|
||||
&& IsNoNickChange(chptr)
|
||||
&& !is_chanownprotop(sptr, chptr))
|
||||
&& !is_chan_op(sptr, chptr))
|
||||
{
|
||||
return HOOK_DENY;
|
||||
}
|
||||
|
||||
return HOOK_ALLOW;
|
||||
}
|
||||
|
||||
@@ -132,7 +132,7 @@ CMD_FUNC(m_part)
|
||||
continue;
|
||||
}
|
||||
|
||||
if (!ValidatePermissionsForPath("channel:override:banpartmsg",sptr,NULL,chptr,NULL) && !is_chanownprotop(sptr, chptr)) {
|
||||
if (!ValidatePermissionsForPath("channel:override:banpartmsg",sptr,NULL,chptr,NULL) && !is_chan_op(sptr, chptr)) {
|
||||
/* Banned? No comment allowed ;) */
|
||||
if (comment && is_banned(sptr, chptr, BANCHK_MSG, &comment, NULL))
|
||||
comment = NULL;
|
||||
|
||||
Reference in New Issue
Block a user