diff options
author | Adam <Adam@drink-coca-cola.info> | 2010-04-24 16:30:49 -0400 |
---|---|---|
committer | Adam <Adam@anope.org> | 2010-06-18 20:55:36 -0400 |
commit | 2ba89de64d3b755f731f202dd97c48d256db8031 (patch) | |
tree | 11534d6d18937a633fd249790c57a9adc6df9735 | |
parent | c4b725b2e1a173c5238160389f6176f4be077221 (diff) |
Tell users when their nicks expire in /ns glist and /ns info
-rw-r--r-- | docs/Changes | 1 | ||||
-rw-r--r-- | lang/cat.l | 6 | ||||
-rw-r--r-- | lang/de.l | 6 | ||||
-rw-r--r-- | lang/en_us.l | 6 | ||||
-rw-r--r-- | lang/es.l | 6 | ||||
-rw-r--r-- | lang/fr.l | 6 | ||||
-rw-r--r-- | lang/gr.l | 6 | ||||
-rw-r--r-- | lang/hun.l | 6 | ||||
-rw-r--r-- | lang/it.l | 6 | ||||
-rw-r--r-- | lang/nl.l | 6 | ||||
-rw-r--r-- | lang/pl.l | 6 | ||||
-rw-r--r-- | lang/pt.l | 6 | ||||
-rw-r--r-- | lang/ru.l | 6 | ||||
-rw-r--r-- | lang/tr.l | 6 | ||||
-rw-r--r-- | src/core/ns_group.c | 14 | ||||
-rw-r--r-- | src/core/ns_info.c | 11 |
16 files changed, 50 insertions, 54 deletions
diff --git a/docs/Changes b/docs/Changes index 0e9cca93d..7f9d83ea6 100644 --- a/docs/Changes +++ b/docs/Changes @@ -1,5 +1,6 @@ Anope Version 1.9.3 -------------------- +A Tell users when their nicks expire in /ns glist and /ns info Anope Version 1.9.2 -------------------- diff --git a/lang/cat.l b/lang/cat.l index 6f2c72183..4e090e340 100644 --- a/lang/cat.l +++ b/lang/cat.l @@ -807,9 +807,9 @@ NICK_GLIST_HEADER_X NICK_GLIST_FOOTER %d nicknames en el grup. NICK_GLIST_REPLY - %c%s -NICK_GLIST_REPLY_ADMIN - %c%s (expires in %s) + %s (expires in %s) +NICK_GLIST_REPLY_NOEXPIRE + %s (does not expire) # RECOVER responses NICK_RECOVER_SYNTAX @@ -825,9 +825,9 @@ NICK_GLIST_HEADER_X NICK_GLIST_FOOTER %d Nicknamen in der Gruppe. NICK_GLIST_REPLY - %c%s -NICK_GLIST_REPLY_ADMIN - %c%s (wird in %s auslaufen) + %s (wird in %s auslaufen) +NICK_GLIST_REPLY_NOEXPIRE + %s (does not expire) # RECOVER responses NICK_RECOVER_SYNTAX diff --git a/lang/en_us.l b/lang/en_us.l index 56fbb8d08..ae526f50a 100644 --- a/lang/en_us.l +++ b/lang/en_us.l @@ -790,9 +790,9 @@ NICK_GLIST_HEADER_X NICK_GLIST_FOOTER %d nicknames in the group. NICK_GLIST_REPLY - %c%s -NICK_GLIST_REPLY_ADMIN - %c%s (expires in %s) + %s (expires in %s) +NICK_GLIST_REPLY_NOEXPIRE + %s (does not expire) # RECOVER responses NICK_RECOVER_SYNTAX @@ -810,9 +810,9 @@ NICK_GLIST_HEADER_X NICK_GLIST_FOOTER %d nicknames en el grupo. NICK_GLIST_REPLY - %c%s -NICK_GLIST_REPLY_ADMIN - %c%s (expires in %s) + %s (expires in %s) +NICK_GLIST_REPLY_NOEXPIRE + %s (does not expire) # RECOVER responses NICK_RECOVER_SYNTAX @@ -817,9 +817,9 @@ NICK_GLIST_HEADER_X NICK_GLIST_FOOTER %d pseudos dans le groupe. NICK_GLIST_REPLY - %c%s -NICK_GLIST_REPLY_ADMIN - %c%s (expire le %s) + %s (expire le %s) +NICK_GLIST_REPLY_NOEXPIRE + %s (does not expire) # RECOVER responses NICK_RECOVER_SYNTAX @@ -805,9 +805,9 @@ NICK_GLIST_HEADER_X NICK_GLIST_FOOTER %d øåõäþíõìá ìÝóá óôçí ïìÜäá. NICK_GLIST_REPLY - %c%s -NICK_GLIST_REPLY_ADMIN - %c%s (expires in %s) + %s (expires in %s) +NICK_GLIST_REPLY_NOEXPIRE + %s (does not expire) # RECOVER responses NICK_RECOVER_SYNTAX diff --git a/lang/hun.l b/lang/hun.l index 2a2bf0ea8..70b8cc831 100644 --- a/lang/hun.l +++ b/lang/hun.l @@ -802,9 +802,9 @@ NICK_GLIST_HEADER_X NICK_GLIST_FOOTER %d nicknév van a csoportban. NICK_GLIST_REPLY - %c%s -NICK_GLIST_REPLY_ADMIN - %c%s (expires in %s) + %s (expires in %s) +NICK_GLIST_REPLY_NOEXPIRE + %s (does not expire) # RECOVER válaszok NICK_RECOVER_SYNTAX @@ -792,9 +792,9 @@ NICK_GLIST_HEADER_X NICK_GLIST_FOOTER %d nick nel gruppo. NICK_GLIST_REPLY - %c%s -NICK_GLIST_REPLY_ADMIN - %c%s (scade tra %s) + %s (scade tra %s) +NICK_GLIST_REPLY_NOEXPIRE + %s (does not expire) # RECOVER responses NICK_RECOVER_SYNTAX @@ -809,9 +809,9 @@ NICK_GLIST_HEADER_X NICK_GLIST_FOOTER %d nicks in de groep. NICK_GLIST_REPLY - %c%s -NICK_GLIST_REPLY_ADMIN - %c%s (expires in %s) + %s (expires in %s) +NICK_GLIST_REPLY_NOEXPIRE + %s (does not expire) # RECOVER responses NICK_RECOVER_SYNTAX @@ -1019,10 +1019,10 @@ NICK_GLIST_FOOTER %d nicków w grupie. NICK_GLIST_REPLY - %c%s + %s (wygasa za %s) -NICK_GLIST_REPLY_ADMIN - %c%s (wygasa za %s) +NICK_GLIST_REPLY_NOEXPIRE + %s (does not expire) # RECOVER responses NICK_RECOVER_SYNTAX @@ -811,9 +811,9 @@ NICK_GLIST_HEADER_X NICK_GLIST_FOOTER %d nicks no grupo. NICK_GLIST_REPLY - %c%s -NICK_GLIST_REPLY_ADMIN - %c%s (expira em %s) + %s (expira em %s) +NICK_GLIST_REPLY_NOEXPIRE + %s (does not expire) # RECOVER responses NICK_RECOVER_SYNTAX @@ -792,9 +792,9 @@ NICK_GLIST_HEADER_X NICK_GLIST_FOOTER Êîëè÷åñòâî íèêîâ â ãðóïïå: %d NICK_GLIST_REPLY - %c%s -NICK_GLIST_REPLY_ADMIN - %c%s (èñòåêàåò %s) + %s (èñòåêàåò %s) +NICK_GLIST_REPLY_NOEXPIRE + %s (does not expire) # RECOVER responses NICK_RECOVER_SYNTAX @@ -812,9 +812,9 @@ NICK_GLIST_HEADER_X NICK_GLIST_FOOTER Grupta %d nick var. NICK_GLIST_REPLY - %c%s -NICK_GLIST_REPLY_ADMIN - %c%s (expires in %s) + %s (expires in %s) +NICK_GLIST_REPLY_NOEXPIRE + %s (does not expire) # RECOVER responses NICK_RECOVER_SYNTAX diff --git a/src/core/ns_group.c b/src/core/ns_group.c index 2aa47ac1f..dab27af27 100644 --- a/src/core/ns_group.c +++ b/src/core/ns_group.c @@ -182,16 +182,14 @@ class CommandNSGList : public Command for (i = 0; i < nc->aliases.count; ++i) { NickAlias *na2 = static_cast<NickAlias *>(nc->aliases.list[i]); - if (na2->nc == nc) + + if (!(wont_expire = na2->HasFlag(NS_NO_EXPIRE))) { - if (!(wont_expire = na2->HasFlag(NS_NO_EXPIRE))) - { - expt = na2->last_seen + Config.NSExpire; - tm = localtime(&expt); - strftime_lang(buf, sizeof(buf), finduser(na2->nick), STRFTIME_DATE_TIME_FORMAT, tm); - } - notice_lang(Config.s_NickServ, u, u->Account()->IsServicesOper() && !wont_expire ? NICK_GLIST_REPLY_ADMIN : NICK_GLIST_REPLY, wont_expire ? '!' : ' ', na2->nick, buf); + expt = na2->last_seen + Config.NSExpire; + tm = localtime(&expt); + strftime_lang(buf, sizeof(buf), finduser(na2->nick), STRFTIME_DATE_TIME_FORMAT, tm); } + notice_lang(Config.s_NickServ, u, wont_expire ? NICK_GLIST_REPLY_NOEXPIRE : NICK_GLIST_REPLY, na2->nick, buf); } notice_lang(Config.s_NickServ, u, NICK_GLIST_FOOTER, nc->aliases.count); } diff --git a/src/core/ns_info.c b/src/core/ns_info.c index 0635e52df..421d33f97 100644 --- a/src/core/ns_info.c +++ b/src/core/ns_info.c @@ -171,13 +171,10 @@ class CommandNSInfo : public Command notice_lang(Config.s_NickServ, u, NICK_INFO_NO_EXPIRE); else { - if (u->Account()->IsServicesOper()) - { - expt = na->last_seen + Config.NSExpire; - tm = localtime(&expt); - strftime_lang(buf, sizeof(buf), finduser(na->nick), STRFTIME_DATE_TIME_FORMAT, tm); - notice_lang(Config.s_NickServ, u, NICK_INFO_EXPIRE, buf); - } + expt = na->last_seen + Config.NSExpire; + tm = localtime(&expt); + strftime_lang(buf, sizeof(buf), finduser(na->nick), STRFTIME_DATE_TIME_FORMAT, tm); + notice_lang(Config.s_NickServ, u, NICK_INFO_EXPIRE, buf); } } |