Skip to content

Commit

Permalink
style: lint
Browse files Browse the repository at this point in the history
  • Loading branch information
dyladan authored Jul 26, 2022
1 parent c86c525 commit b065758
Showing 1 changed file with 3 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -41,16 +41,12 @@ export class InMemoryMetricExporter implements PushMetricExporter {
export(metrics: ResourceMetrics, resultCallback: (result: ExportResult) => void): void {
// Avoid storing metrics when exporter is shutdown
if (this. _shutdown) {
setTimeout(() => {
resultCallback({ code: ExportResultCode.FAILED })
}, 0);
setTimeout(() => resultCallback({ code: ExportResultCode.FAILED }), 0);
return;
}

this._metrics.push(metrics);
setTimeout(() => {
resultCallback({ code: ExportResultCode.SUCCESS })
}, 0);
setTimeout(() => resultCallback({ code: ExportResultCode.SUCCESS }), 0);
}

/**
Expand All @@ -61,7 +57,7 @@ export class InMemoryMetricExporter implements PushMetricExporter {
return this._metrics;
}

async forceFlush() {
forceFlush(): Promise<void> {
return Promise.resolve();
}

Expand Down

0 comments on commit b065758

Please sign in to comment.