summaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
authorFlorent Le Coz <louiz@louiz.org>2013-05-01 18:52:29 +0200
committerFlorent Le Coz <louiz@louiz.org>2013-05-01 18:52:29 +0200
commit48aa8d0bda5d5e61a41e00301cc15c07e47a2237 (patch)
treefc33654f0166d24f01578f5b82c42aa22b795162 /plugins
parent5ff6e2a8c62c365b1d4e6d63496ae961ef2994d1 (diff)
downloadpoezio-48aa8d0bda5d5e61a41e00301cc15c07e47a2237.tar.gz
poezio-48aa8d0bda5d5e61a41e00301cc15c07e47a2237.tar.bz2
poezio-48aa8d0bda5d5e61a41e00301cc15c07e47a2237.tar.xz
poezio-48aa8d0bda5d5e61a41e00301cc15c07e47a2237.zip
Actually have a random nick ONLY when our nick is RANDOM
Diffstat (limited to 'plugins')
-rw-r--r--plugins/random_nick.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/plugins/random_nick.py b/plugins/random_nick.py
index b73ec247..59ba47d9 100644
--- a/plugins/random_nick.py
+++ b/plugins/random_nick.py
@@ -27,8 +27,9 @@ class Plugin(BasePlugin):
def change_nick_to_random(self, presence):
to = presence["to"]
- to.resource = gen_nick(3)
- presence["to"] = to
+ if to.resource == 'RANDOM':
+ to.resource = gen_nick(3)
+ presence["to"] = to
s = ["i", "ou", "ou", "on", "a", "o", "u", "i"]
c = ["b", "c", "d", "f", "g", "h", "j", "k", "m", "l", "n", "p", "r", "s", "t", "v", "z"]