From 56bdda17b70b23c0b0af4b413432bc65b43a3654 Mon Sep 17 00:00:00 2001 From: Steve Nyemba Date: Thu, 30 Nov 2023 12:40:57 -0600 Subject: [PATCH] minor bug fix --- transport/disk.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/transport/disk.py b/transport/disk.py index 956386d..42b5b33 100644 --- a/transport/disk.py +++ b/transport/disk.py @@ -219,9 +219,10 @@ class SQLiteWriter(SQLite,DiskWriter) : elif type(info) == pd.DataFrame : info = info.fillna('') info = info.to_dict(orient='records') - if not self.fields : - _rec = info[0] - self.init(list(_rec.keys())) + + if not self.fields : + _rec = info[0] + self.init(list(_rec.keys())) SQLiteWriter.LOCK.acquire() try: