Skip to content

Commit

Permalink
[ci] format
Browse files Browse the repository at this point in the history
  • Loading branch information
matthewp authored and astrobot-houston committed May 21, 2024
1 parent e14ce57 commit f00ecd4
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions packages/db/src/runtime/db-client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -78,14 +78,14 @@ export function createRemoteDatabaseClient(appToken: string, remoteDbURL: string
// Using `db.run()` drizzle massages the rows into an object.
// So in order to make dev/prod consistent, we need to do the same here.
// This creates an object and loops over each row replacing it with the object.
for(let i = 0; i < remoteResult.rows.length; i++) {
let row = remoteResult.rows[i];
let item: Record<string, any> = {};
remoteResult.columns.forEach((col, index) => {
item[col] = row[index];
});
(remoteResult as any).rows[i] = item;
}
for (let i = 0; i < remoteResult.rows.length; i++) {
let row = remoteResult.rows[i];
let item: Record<string, any> = {};
remoteResult.columns.forEach((col, index) => {
item[col] = row[index];
});
(remoteResult as any).rows[i] = item;
}
return remoteResult;
}

Expand Down

0 comments on commit f00ecd4

Please sign in to comment.