Skip to content

Commit

Permalink
Merge pull request #8 from PinataCloud/fix/clean-up-analytics
Browse files Browse the repository at this point in the history
fix: Removed some unused code and updated name for source header
  • Loading branch information
stevedylandev authored Aug 16, 2024
2 parents c2ede11 + a9ea675 commit 4e51ed3
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 10 deletions.
2 changes: 1 addition & 1 deletion src/core/gateway/analyticsDateInterval.ts
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ export const analyticsDateInterval = async (
} else {
headers = {
Authorization: `Bearer ${config.pinataJwt}`,
Source: "sdk/analyticsTopUsage",
Source: "sdk/analyticsDateInterval",
};
}

Expand Down
8 changes: 0 additions & 8 deletions src/core/pinataSDK.ts
Original file line number Diff line number Diff line change
Expand Up @@ -966,11 +966,3 @@ class TimeIntervalGatewayAnalyticsBuilder extends GatewayAnalyticsBuilder<
return this.getAnalytics();
}
}

class GatewayAnalytics {
private config: PinataConfig | undefined;

constructor(config?: PinataConfig) {
this.config = config;
}
}
2 changes: 1 addition & 1 deletion tests/gateway/analyticsDateInterval.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ describe("analyticsDateInterval function", () => {
expect.objectContaining({
method: "GET",
headers: {
Source: "sdk/analyticsTopUsage",
Source: "sdk/analyticsDateInterval",
Authorization: `Bearer ${mockConfig.pinataJwt}`,
},
}),
Expand Down

0 comments on commit 4e51ed3

Please sign in to comment.