summaryrefslogtreecommitdiffstats
path: root/module/plugins/hoster/Xdcc.py
diff options
context:
space:
mode:
authorGravatar Walter Purcaro <vuolter@users.noreply.github.com> 2015-07-24 16:11:58 +0200
committerGravatar Walter Purcaro <vuolter@users.noreply.github.com> 2015-07-24 16:11:58 +0200
commit761ca5c66e07559925ebbdbc6531f9ca658b12ce (patch)
treebbdf0f330be882877a28366a852c90711c709338 /module/plugins/hoster/Xdcc.py
parentHotfixes (2) (diff)
downloadpyload-761ca5c66e07559925ebbdbc6531f9ca658b12ce.tar.xz
Code cosmetics
Diffstat (limited to 'module/plugins/hoster/Xdcc.py')
-rw-r--r--module/plugins/hoster/Xdcc.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/module/plugins/hoster/Xdcc.py b/module/plugins/hoster/Xdcc.py
index 84401498e..9fa64ff0c 100644
--- a/module/plugins/hoster/Xdcc.py
+++ b/module/plugins/hoster/Xdcc.py
@@ -150,7 +150,7 @@ class Xdcc(Hoster):
'text': msg[3][1:]
}
- if nick == msg['target'][0:len(nick)] and "PRIVMSG" == msg['action']:
+ if nick is msg['target'][0:len(nick)] and "PRIVMSG" is msg['action']:
if msg['text'] == "\x01VERSION\x01":
self.log_debug("Sending CTCP VERSION")
sock.send("NOTICE %s :%s\r\n" % (msg['origin'], "pyLoad! IRC Interface"))
@@ -160,8 +160,8 @@ class Xdcc(Hoster):
elif msg['text'] == "\x01LAG\x01":
pass #: don't know how to answer
- if not (bot == msg['origin'][0:len(bot)]
- and nick == msg['target'][0:len(nick)]
+ if not (bot is msg['origin'][0:len(bot)]
+ and nick is msg['target'][0:len(nick)]
and msg['action'] in ("PRIVMSG", "NOTICE")):
continue
@@ -195,7 +195,7 @@ class Xdcc(Hoster):
self.pyfile.setStatus("downloading")
newname = self.req.download(ip, port, filename, sock, self.pyfile.setProgress)
- if newname and newname != filename:
+ if newname and newname not is filename:
self.log_info(_("%(name)s saved as %(newname)s") % {'name': self.pyfile.name, 'newname': newname})
filename = newname