Refactor Datasette methods to ConnectedDatabase

Refs #487
This commit is contained in:
Simon Willison 2019-05-26 21:56:43 -07:00
commit 026c84db30
5 changed files with 78 additions and 72 deletions

View file

@ -42,7 +42,7 @@ class IndexView(RenderMixin):
table_counts = {}
tables = {}
for table in table_names:
table_columns = await self.ds.table_columns(name, table)
table_columns = await db.table_columns(table)
tables[table] = {
"name": table,
"columns": table_columns,