Skip to content

Commit

Permalink
v1.2.1: removed dependency of package.json
Browse files Browse the repository at this point in the history
  • Loading branch information
sanjoyment committed Feb 8, 2024
1 parent 5a0921c commit 9c8d270
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
3 changes: 1 addition & 2 deletions index.node.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ const { OTLPLogExporter } = require('@opentelemetry/exporter-logs-otlp-grpc');
const { LoggerProvider, SimpleLogRecordProcessor } = require('@opentelemetry/sdk-logs');

const fs = require('fs');
const packageJson = JSON.parse(fs.readFileSync('./package.json', 'utf8'));

module.exports.track = (args = {}) => {

Expand Down Expand Up @@ -113,7 +112,7 @@ const setupLogger = (hostUrl, resourceAttributes) => {
};

const logger = (level, message, attributes = {}) => {
const logger = logs.getLogger(packageJson.name, packageJson.version);
const logger = logs.getLogger("@middleware.io/agent-apm-nextjs", "latest");

logger.emit({
severityNumber: SeverityNumber[level],
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@middleware.io/agent-apm-nextjs",
"version": "1.2.0",
"version": "1.2.1",
"description": "Agent APM for NextJs",
"main": "index.node.js",
"scripts": {
Expand Down

0 comments on commit 9c8d270

Please sign in to comment.