-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
7 changed files
with
217 additions
and
252 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
import { convertIntegrationFnToClass } from '@sentry/core'; | ||
import type { IntegrationFn } from '@sentry/types'; | ||
import { NODE_VERSION } from '../../nodeVersion'; | ||
import type { Options } from './common'; | ||
import { localVariablesAsync } from './local-variables-async'; | ||
import { localVariablesSync } from './local-variables-sync'; | ||
|
||
const INTEGRATION_NAME = 'LocalVariables'; | ||
|
||
/** | ||
* Adds local variables to exception frames | ||
*/ | ||
const localVariables: IntegrationFn = (options: Options = {}) => { | ||
return NODE_VERSION.major < 19 ? localVariablesSync(options) : localVariablesAsync(options); | ||
}; | ||
|
||
/** | ||
* Adds local variables to exception frames | ||
*/ | ||
// eslint-disable-next-line deprecation/deprecation | ||
export const LocalVariables = convertIntegrationFnToClass(INTEGRATION_NAME, localVariables); |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.