From 28fd4050c782e675745feea719e745a339f73200 Mon Sep 17 00:00:00 2001 From: XANTRONIX Industrial Date: Fri, 14 Feb 2025 13:48:16 -0500 Subject: [PATCH] Prune down Database.column_placeholders() a bit --- lib/nexrad/db.py | 18 +----------------- 1 file changed, 1 insertion(+), 17 deletions(-) diff --git a/lib/nexrad/db.py b/lib/nexrad/db.py index ec32a2c..95161af 100644 --- a/lib/nexrad/db.py +++ b/lib/nexrad/db.py @@ -108,23 +108,7 @@ class Database(): return Database(db) def column_placeholders(self, table, obj) -> list: - ctors = getattr(table, '__constructors__') - - if ctors is None: - return ['?' for c in table.__columns__ if c != table.__key__] - if ctors is not None: - ret = list() - - for c in table.__columns__: - if c == table.__key__: - continue - - if c in ctors: - ret.append(ctors[c](getattr(obj, c))) - else: - ret.append('?') - - return ret + return ['?' for c in table.__columns__ if c != table.__key__] def add(self, obj): fn = getattr(obj, '__insert__')