Skip to content

Commit f618083

Browse files
committed
Fix bug simonw#1
variable name collision
1 parent 1d1e1e8 commit f618083

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

Diff for: dbf_to_sqlite/cli.py

+5-5
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,9 @@ def cli(dbf_paths, sqlite_db, table, verbose):
2323
table_name = table if table else Path(path).stem
2424
if verbose:
2525
click.echo('Loading {} into table "{}"'.format(path, table_name))
26-
table = dbf.Table(str(path))
27-
table.open()
28-
columns = table.field_names
29-
db[table_name].insert_all(dict(zip(columns, list(row))) for row in table)
30-
table.close()
26+
dbf_table = dbf.Table(str(path))
27+
dbf_table.open()
28+
columns = dbf_table.field_names
29+
db[table_name].insert_all(dict(zip(columns, list(row))) for row in dbf_table)
30+
dbf_table.close()
3131
db.vacuum()

0 commit comments

Comments
 (0)