Skip to content
Snippets Groups Projects
Commit f4a203d5 authored by dkirov's avatar dkirov
Browse files

better pass of args

parent 7e69364f
No related branches found
No related tags found
No related merge requests found
......@@ -118,7 +118,7 @@ class Logger:
possible_room_jid, possible_nick = jid.split('/', 1)
self.cur.execute('SELECT jid_id FROM jids WHERE jid="%s" AND type=%d' %\
self.cur.execute('SELECT jid_id FROM jids WHERE jid=? AND type=?',
(possible_room_jid, constants.JID_ROOM_TYPE))
row = self.cur.fetchone()
if row is None:
......@@ -139,7 +139,7 @@ class Logger:
if not jid_is_from_pm: # it's normal jid with resource
jid = jid.split('/', 1)[0] # remove the resource
if jid in self.jids_already_in: # we already have jids in DB
self.cur.execute('SELECT jid_id FROM jids WHERE jid="%s"' % jid)
self.cur.execute('SELECT jid_id FROM jids WHERE jid=?', [jid])
jid_id = self.cur.fetchone()[0]
else: # oh! a new jid :), we add it now
if typestr == 'ROOM':
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment