- return 0;
-
- /* Not exempt, BOOK EM DANNO! */
- user->WriteServ("NOTICE %s :*** You cannot list within the first %lu seconds of connecting. Please try again later.",user->nick.c_str(), (unsigned long) WaitTime);
- /* Some crap clients (read: mIRC, various java chat applets) muck up if they don't
- * receive these numerics whenever they send LIST, so give them an empty LIST to mull over.
- */
- user->WriteNumeric(321, "%s Channel :Users Name",user->nick.c_str());
- user->WriteNumeric(323, "%s :End of channel list.",user->nick.c_str());
- return 1;
+ return MOD_RES_PASSTHRU;
+
+ const AccountExtItem* ext = GetAccountExtItem();
+ if (exemptregistered && ext && ext->get(user))
+ return MOD_RES_PASSTHRU;
+
+ if (showmsg)
+ {
+ user->WriteNotice(InspIRCd::Format("*** You cannot view the channel list right now. Please %stry again in %s.",
+ (exemptregistered ? "login to an account or " : ""),
+ InspIRCd::DurationString(waitallowed - ServerInstance->Time()).c_str()));
+ }
+
+ // The client might be waiting on a response to do something so send them an
+ // empty list response to satisfy that.
+ user->WriteNumeric(RPL_LISTSTART, "Channel", "Users Name");
+ user->WriteNumeric(RPL_LISTEND, "End of channel list.");
+ return MOD_RES_DENY;