Skip to content

Commit

Permalink
remove logging
Browse files Browse the repository at this point in the history
  • Loading branch information
avermeil committed Mar 20, 2024
1 parent 42479c0 commit 4fa4623
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/customer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -344,24 +344,22 @@ export class Customer extends ServiceFactory {

const accumulator: services.IGoogleAdsRow[] = [];
let foundSummaryRow: services.IGoogleAdsRow | undefined;
console.time("total parsing");

for (const { results, summaryRow } of JSON.parse(asString)) {
if (summaryRow) {
foundSummaryRow = this.decamelizeKeysIfNeeded(summaryRow);
}
console.time("parsing");

accumulator.push(
...(results ?? []).map((row: any) => {
return this.decamelizeKeysIfNeeded(row);
})
);
console.timeEnd("parsing");

if (foundSummaryRow) {
accumulator.unshift(foundSummaryRow);
}
}
console.timeEnd("total parsing");

return { response: accumulator };
} catch (e: any) {
Expand Down

0 comments on commit 4fa4623

Please sign in to comment.