added get_server to Database.py, for some future use. dunno.
This commit is contained in:
parent
863bebb14e
commit
5a27823244
1 changed files with 5 additions and 0 deletions
|
@ -180,3 +180,8 @@ class Database(object):
|
||||||
self.cursor().execute("""SELECT server_id, hostname, port, password,
|
self.cursor().execute("""SELECT server_id, hostname, port, password,
|
||||||
ipv4, tls, nickname, username, realname FROM servers""")
|
ipv4, tls, nickname, username, realname FROM servers""")
|
||||||
return self.cursor().fetchall()
|
return self.cursor().fetchall()
|
||||||
|
def get_server(self, id):
|
||||||
|
self.cursor().execute("""SELECT server_id, hostname, port, password,
|
||||||
|
ipv4, tls, nickname, username, realname FROM servers WHERE
|
||||||
|
server_id=?""", [id])
|
||||||
|
return self.cursors.fetchall()
|
||||||
|
|
Loading…
Reference in a new issue