Skip to content

Commit 4ee0cd2

Browse files
authored
fix: Typo arrity -> arity (#2871)
1 parent 4d8abee commit 4ee0cd2

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
lines changed

packages/apm/src/integrations/express.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -79,9 +79,9 @@ export class Express implements Integration {
7979
*/
8080
// eslint-disable-next-line @typescript-eslint/ban-types
8181
function wrap(fn: Function): RequestHandler | ErrorRequestHandler {
82-
const arrity = fn.length;
82+
const arity = fn.length;
8383

84-
switch (arrity) {
84+
switch (arity) {
8585
case 2: {
8686
return function(this: NodeJS.Global, _req: Request, res: Response & SentryTracingResponse): any {
8787
const transaction = res.__sentry_transaction;
@@ -143,7 +143,7 @@ function wrap(fn: Function): RequestHandler | ErrorRequestHandler {
143143
};
144144
}
145145
default: {
146-
throw new Error(`Express middleware takes 2-4 arguments. Got: ${arrity}`);
146+
throw new Error(`Express middleware takes 2-4 arguments. Got: ${arity}`);
147147
}
148148
}
149149
}

packages/minimal/src/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ export function captureMessage(message: string, captureContext?: CaptureContext
6363
}
6464

6565
// This is necessary to provide explicit scopes upgrade, without changing the original
66-
// arrity of the `captureMessage(message, level)` method.
66+
// arity of the `captureMessage(message, level)` method.
6767
const level = typeof captureContext === 'string' ? captureContext : undefined;
6868
const context = typeof captureContext !== 'string' ? { captureContext } : undefined;
6969

packages/tracing/src/integrations/express.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -78,9 +78,9 @@ export class Express implements Integration {
7878
*/
7979
// eslint-disable-next-line @typescript-eslint/ban-types
8080
function wrap(fn: Function): RequestHandler | ErrorRequestHandler {
81-
const arrity = fn.length;
81+
const arity = fn.length;
8282

83-
switch (arrity) {
83+
switch (arity) {
8484
case 2: {
8585
return function(this: NodeJS.Global, _req: Request, res: Response & SentryTracingResponse): any {
8686
const transaction = res.__sentry_transaction;
@@ -145,7 +145,7 @@ function wrap(fn: Function): RequestHandler | ErrorRequestHandler {
145145
};
146146
}
147147
default: {
148-
throw new Error(`Express middleware takes 2-4 arguments. Got: ${arrity}`);
148+
throw new Error(`Express middleware takes 2-4 arguments. Got: ${arity}`);
149149
}
150150
}
151151
}

0 commit comments

Comments
 (0)