Skip to content

Commit 2ffa523

Browse files
authored
fix: typo in unauthenticated error message (#28)
1 parent e76aa99 commit 2ffa523

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/hook.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ export async function hook(
2626

2727
if (MUTATING_METHODS.includes(endpoint.method)) {
2828
throw new RequestError(
29-
`"${endpoint.method} ${endpoint.url}" is not permitted due to lack authentication. Reason: ${reason}`,
29+
`"${endpoint.method} ${endpoint.url}" is not permitted due to lack of authentication. Reason: ${reason}`,
3030
403,
3131
{
3232
request: request.endpoint.parse(endpoint),

test/index.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@ test('auth.hook(request, "PATCH /repos/octocat/hello-world") fails without sendi
192192
throw new Error("should not resolve");
193193
} catch (error) {
194194
expect(error.message).toBe(
195-
'"PATCH /repos/octocat/hello-world" is not permitted due to lack authentication. Reason: test'
195+
'"PATCH /repos/octocat/hello-world" is not permitted due to lack of authentication. Reason: test'
196196
);
197197
}
198198
});

0 commit comments

Comments
 (0)