diff --git a/nandod b/nandod index 4eee971..b9c9312 100755 --- a/nandod +++ b/nandod @@ -85,7 +85,11 @@ class DataBase: except: return self.db=self.conn.cursor() - self.db.execute("INSERT OR REPLACE INTO alive(id,ip,date,desc) \ + if desc is "": + self.db.execute("INSERT OR REPLACE INTO alive(id,ip,date) \ + VALUES(?,?,?)",(host,ip,int(time.time()))) + else: + self.db.execute("INSERT OR REPLACE INTO alive(id,ip,date,desc) \ VALUES(?,?,?,?)",(host,ip,int(time.time()),desc)) self.conn_end()