bug fix
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
ci/woodpecker/pr/woodpecker Pipeline was successful

This commit is contained in:
jusax23 2023-02-27 17:59:16 +01:00
parent 53cb448e36
commit cbac881a49
2 changed files with 4 additions and 2 deletions

View file

@ -101,7 +101,7 @@ export class selectQuery {
const builder = this.serialize(handler); const builder = this.serialize(handler);
const s = handler.builders.query(builder); const s = handler.builders.query(builder);
let readResp = await db.query(s, printQuery); let readResp = await db.query(s, printQuery);
return db.getHandler().responses.readResponse(readResp); return handler.responses.readResponse(readResp);
} }
} }

View file

@ -15,7 +15,9 @@ export class singleResponse {
export class readResponse extends Array<singleResponse>{ export class readResponse extends Array<singleResponse>{
constructor(rows: ({ [key: string]: primaryData })[]) { constructor(rows: ({ [key: string]: primaryData })[]) {
super(); super();
this.push(...rows.map(r => new singleResponse(r))); for(let i = 0; i < rows.length; i++){
this[i] = new singleResponse(rows[i])
}
} }
} }