| View previous topic :: View next topic |
| Author |
Message |
juanamores Master
Joined: 15 Mar 2015 Posts: 317
|
Posted: Thu Aug 20, 2015 10:53 pm Post subject: validuser case sensitive |
|
|
I wish that when someone adds a nick as DJ, compare whether the addition nick is a valid user on the bot.
But compare that to be case sensitive.
Example for valid user freud
!djadd freud
OK
For invalid user FrEuD
NOT VALID
This code is NOT case sensitive:
if {![validuser $djnickname]} { putmsg $chan NOT VALID }
How I can do to make the validuser command case sensitive? _________________ If you do not understand my ideas is because I can not think in English, I help me with Google Translate. I only speak Spanish. Bear with me. Thanks  |
|
| Back to top |
|
 |
Get_A_Fix Master

Joined: 07 May 2005 Posts: 206 Location: New Zealand
|
Posted: Sat Aug 22, 2015 6:02 am Post subject: |
|
|
it doesn't have to be case sensitive, as long as it can match the users host.
I would try something like
| Code: |
if {![validuser [nick2hand $djnickname]]} { putmsg $chan "NOT VALID" }
|
if that doesn't work, then you may have to use lsearch and -nocase switch. _________________ We explore.. and you call us criminals. We seek after knowledge.. and you call us criminals. We exist without skin color, without nationality, without religious bias.. and you call us criminals. |
|
| Back to top |
|
 |
juanamores Master
Joined: 15 Mar 2015 Posts: 317
|
Posted: Sun Aug 23, 2015 5:10 am Post subject: |
|
|
I'll try, thanks. _________________ If you do not understand my ideas is because I can not think in English, I help me with Google Translate. I only speak Spanish. Bear with me. Thanks  |
|
| Back to top |
|
 |
|