Skip to content

Commit

Permalink
fix: Replace require with import
Browse files Browse the repository at this point in the history
  • Loading branch information
ddeboer committed Jul 21, 2023
1 parent 0f20b2a commit 30b2c5c
Showing 1 changed file with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ import {
OTLPExporterError,
OTLPExporterNodeConfigBase,
} from '@opentelemetry/otlp-exporter-base';
import { send } from './util';

type SendFn = <ExportItem, ServiceRequest>(
collector: OTLPProtoExporterNodeBase<ExportItem, ServiceRequest>,
Expand Down Expand Up @@ -74,8 +75,6 @@ export abstract class OTLPProtoExporterNodeBase<
// defer to next tick and lazy load to avoid loading protobufjs too early
// and making this impossible to be instrumented
setImmediate(() => {
// eslint-disable-next-line @typescript-eslint/no-var-requires
const { send } = require('./util');
this._send = send;
this._sendPromise(objects, onSuccess, onError);
});
Expand Down

0 comments on commit 30b2c5c

Please sign in to comment.