]> jfr.im git - irc/quakenet/newserv.git/blobdiff - chanserv/newsearch/csns-qemail.c
HELPMOD2: don't ignore +h clients
[irc/quakenet/newserv.git] / chanserv / newsearch / csns-qemail.c
index 6db9fea5bfc840870ab2feda9488d941dd7eca27..f97ff605ca5fa4261c1fcb7bbffc3cf45c7876be 100644 (file)
 void *qemail_exe(searchCtx *ctx, struct searchNode *thenode, void *theinput);
 void qemail_free(searchCtx *ctx, struct searchNode *thenode);
 
-struct searchNode *qemail_parse(searchCtx *ctx, int type, int argc, char **argv) {
+struct searchNode *qemail_parse(searchCtx *ctx, int argc, char **argv) {
   struct searchNode *thenode;
 
-  if (type != SEARCHTYPE_USER) {
-    parseError = "qemail: this function is only valid for user searches.";
-    return NULL;
-  }
-
   if (!(thenode=(struct searchNode *)malloc(sizeof (struct searchNode)))) {
     parseError = "malloc: could not allocate memory for this search.";
     return NULL;
@@ -32,7 +27,7 @@ struct searchNode *qemail_parse(searchCtx *ctx, int type, int argc, char **argv)
 
 void *qemail_exe(searchCtx *ctx, struct searchNode *thenode, void *theinput) {
   authname *ap = (authname *)theinput;
-  reguser *rup = ap->exts[chanservext];
+  reguser *rup = ap->exts[chanservaext];
   if(!rup || !rup->email)
     return "";