Skip to content
This repository has been archived by the owner on Oct 27, 2024. It is now read-only.

Commit

Permalink
fix api key header name
Browse files Browse the repository at this point in the history
  • Loading branch information
mat-1 committed Mar 26, 2022
1 parent 99d4450 commit 3c570c9
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "typed-hypixel-api",
"version": "0.2.2",
"version": "0.2.3",
"main": "build/index.js",
"types": "build/index.d.js",
"repository": "https://github.com/skyblockstats/typed-hypixel-api.git",
Expand Down
2 changes: 1 addition & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ export const request = async<P extends keyof Requests>(path: P, options: Request
if (options)
for (const [optionName, optionValue] of Object.entries(options)) {
if (optionName === 'key') {
requestHeaders.set('X-Api-Key', optionValue)
requestHeaders.set('Api-Key', optionValue)
} else {
requestParameters[optionName] = optionValue
}
Expand Down

0 comments on commit 3c570c9

Please sign in to comment.