X-Git-Url: https://jfr.im/git/irc/quakenet/newserv.git/blobdiff_plain/511881d68574d23a14cd2a38e0af7a806fee15c4..12895bd4c6c0d1eef32d48404e65b223b74b511d:/chanserv/chancmds/giveowner.c diff --git a/chanserv/chancmds/giveowner.c b/chanserv/chancmds/giveowner.c index 2a19cc7a..68eafc97 100644 --- a/chanserv/chancmds/giveowner.c +++ b/chanserv/chancmds/giveowner.c @@ -58,17 +58,17 @@ int csc_dogiveowner(void *source, int cargc, char **cargv) { rcup=findreguseronchannel(rcp, target); - /* You can only promote a master */ - if (!rcup || !(rcup->flags & QCUFLAG_MASTER)) { - chanservstdmessage(sender,QM_GIVEOWNERNOTMASTER,target->username,cip->name->content); - return CMD_ERROR; - } - /* Can't promote if already owner */ if (rcup->flags & QCUFLAG_OWNER) { chanservstdmessage(sender,QM_GIVEOWNERALREADYOWNER,target->username,cip->name->content); return CMD_ERROR; } + + /* You can only promote a master */ + if (!rcup || !(rcup->flags & QCUFLAG_MASTER)) { + chanservstdmessage(sender,QM_GIVEOWNERNOTMASTER,target->username,cip->name->content); + return CMD_ERROR; + } /* Compute ze hash */ sprintf(hashstr,"%u.%u.%u",rcp->ID,target->ID,rup->ID);