Skip to content

Commit 639f720

Browse files
committed
fixup! refactor(resource-detector-aws): migrate away from getEnv()
1 parent 8dbbb81 commit 639f720

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

detectors/node/opentelemetry-resource-detector-aws/src/detectors/AwsEcsDetectorSync.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,10 @@ export class AwsEcsDetectorSync implements DetectorSync {
7676
}
7777

7878
private async _getAttributes(): Promise<ResourceAttributes> {
79-
if (!process.env.ECS_CONTAINER_METADATA_URI_V4 && !process.env.ECS_CONTAINER_METADATA_URI) {
79+
if (
80+
!process.env.ECS_CONTAINER_METADATA_URI_V4 &&
81+
!process.env.ECS_CONTAINER_METADATA_URI
82+
) {
8083
diag.debug('AwsEcsDetector failed: Process is not on ECS');
8184
return {};
8285
}

0 commit comments

Comments
 (0)