Skip to content

Commit 7f54143

Browse files
authored
chore: Upgrade prettier to 2.8.7 (#7832)
1 parent 371f80d commit 7f54143

File tree

9 files changed

+18
-13
lines changed

9 files changed

+18
-13
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@
102102
"mocha": "^6.1.4",
103103
"nodemon": "^2.0.16",
104104
"npm-run-all": "^4.1.5",
105-
"prettier": "2.7.1",
105+
"prettier": "2.8.7",
106106
"recast": "^0.20.5",
107107
"replace-in-file": "^4.0.0",
108108
"rimraf": "^3.0.2",

packages/core/src/tracing/idletransaction.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ export class IdleTransaction extends Transaction {
9090
*/
9191
private _idleTimeoutID: ReturnType<typeof setTimeout> | undefined;
9292

93-
private _finishReason: typeof IDLE_TRANSACTION_FINISH_REASONS[number] = IDLE_TRANSACTION_FINISH_REASONS[4];
93+
private _finishReason: (typeof IDLE_TRANSACTION_FINISH_REASONS)[number] = IDLE_TRANSACTION_FINISH_REASONS[4];
9494

9595
public constructor(
9696
transactionContext: TransactionContext,

packages/nextjs/src/client/wrapAppGetInitialPropsWithSentry.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import type App from 'next/app';
22

3-
type AppGetInitialProps = typeof App['getInitialProps'];
3+
type AppGetInitialProps = (typeof App)['getInitialProps'];
44

55
/**
66
* A passthrough function in case this function is used on the clientside. We need to make the returned function async

packages/nextjs/src/server/wrapAppGetInitialPropsWithSentry.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import {
1010
withTracedServerSideDataFetcher,
1111
} from './utils/wrapperUtils';
1212

13-
type AppGetInitialProps = typeof App['getInitialProps'];
13+
type AppGetInitialProps = (typeof App)['getInitialProps'];
1414

1515
/**
1616
* Create a wrapped version of the user's exported `getInitialProps` function in

packages/node/src/requestdata.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,9 @@ export type AddRequestDataToEventOptions = {
2525
/** Flags controlling whether each type of data should be added to the event */
2626
include?: {
2727
ip?: boolean;
28-
request?: boolean | Array<typeof DEFAULT_REQUEST_INCLUDES[number]>;
28+
request?: boolean | Array<(typeof DEFAULT_REQUEST_INCLUDES)[number]>;
2929
transaction?: boolean | TransactionNamingScheme;
30-
user?: boolean | Array<typeof DEFAULT_USER_INCLUDES[number]>;
30+
user?: boolean | Array<(typeof DEFAULT_USER_INCLUDES)[number]>;
3131
};
3232
};
3333

packages/tracing-internal/src/node/integrations/mongo.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import { shouldDisableAutoInstrumentation } from './utils/node-utils';
88
// This allows us to use the same array for both defaults options and the type itself.
99
// (note `as const` at the end to make it a union of string literal types (i.e. "a" | "b" | ... )
1010
// and not just a string[])
11-
type Operation = typeof OPERATIONS[number];
11+
type Operation = (typeof OPERATIONS)[number];
1212
const OPERATIONS = [
1313
'aggregate', // aggregate(pipeline, options, callback)
1414
'bulkWrite', // bulkWrite(operations, options, callback)

packages/utils/src/instrument.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -624,7 +624,7 @@ function instrumentDOM(): void {
624624
});
625625
}
626626

627-
let _oldOnErrorHandler: typeof WINDOW['onerror'] | null = null;
627+
let _oldOnErrorHandler: (typeof WINDOW)['onerror'] | null = null;
628628
/** JSDoc */
629629
function instrumentError(): void {
630630
_oldOnErrorHandler = WINDOW.onerror;
@@ -649,7 +649,7 @@ function instrumentError(): void {
649649
WINDOW.onerror.__SENTRY_INSTRUMENTED__ = true;
650650
}
651651

652-
let _oldOnUnhandledRejectionHandler: typeof WINDOW['onunhandledrejection'] | null = null;
652+
let _oldOnUnhandledRejectionHandler: (typeof WINDOW)['onunhandledrejection'] | null = null;
653653
/** JSDoc */
654654
function instrumentUnhandledRejection(): void {
655655
_oldOnUnhandledRejectionHandler = WINDOW.onunhandledrejection;

packages/utils/src/logger.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,10 @@ import { getGlobalSingleton, GLOBAL_OBJ } from './worldwide';
66
const PREFIX = 'Sentry Logger ';
77

88
export const CONSOLE_LEVELS = ['debug', 'info', 'warn', 'error', 'log', 'assert', 'trace'] as const;
9-
export type ConsoleLevel = typeof CONSOLE_LEVELS[number];
9+
export type ConsoleLevel = (typeof CONSOLE_LEVELS)[number];
1010

1111
type LoggerMethod = (...args: unknown[]) => void;
12-
type LoggerConsoleMethods = Record<typeof CONSOLE_LEVELS[number], LoggerMethod>;
12+
type LoggerConsoleMethods = Record<(typeof CONSOLE_LEVELS)[number], LoggerMethod>;
1313

1414
/** JSDoc */
1515
interface Logger extends LoggerConsoleMethods {
@@ -47,7 +47,7 @@ export function consoleSandbox<T>(callback: () => T): T {
4747
} finally {
4848
// Revert restoration to wrapped state
4949
Object.keys(wrappedLevels).forEach(level => {
50-
originalConsole[level] = wrappedLevels[level as typeof CONSOLE_LEVELS[number]];
50+
originalConsole[level] = wrappedLevels[level as (typeof CONSOLE_LEVELS)[number]];
5151
});
5252
}
5353
}

yarn.lock

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22093,7 +22093,12 @@ prepend-http@^2.0.0:
2209322093
resolved "https://registry.yarnpkg.com/prepend-http/-/prepend-http-2.0.0.tgz#e92434bfa5ea8c19f41cdfd401d741a3c819d897"
2209422094
integrity sha1-6SQ0v6XqjBn0HN/UAddBo8gZ2Jc=
2209522095

22096-
[email protected], prettier@^2.5.1:
22096+
22097+
version "2.8.7"
22098+
resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.8.7.tgz#bb79fc8729308549d28fe3a98fce73d2c0656450"
22099+
integrity sha512-yPngTo3aXUUmyuTjeTUT75txrf+aMh9FiD7q9ZE/i6r0bPb22g4FsE6Y338PQX1bmfy08i9QQCB7/rcUAVntfw==
22100+
22101+
prettier@^2.5.1:
2209722102
version "2.7.1"
2209822103
resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.7.1.tgz#e235806850d057f97bb08368a4f7d899f7760c64"
2209922104
integrity sha512-ujppO+MkdPqoVINuDFDRLClm7D78qbDt0/NR+wp5FqEZOoTNAjPHWj17QRhu7geIHJfcNhRk1XVQmF8Bp3ye+g==

0 commit comments

Comments
 (0)