File tree Expand file tree Collapse file tree 2 files changed +2
-1
lines changed
packages/core/src/tracing Expand file tree Collapse file tree 2 files changed +2
-1
lines changed Original file line number Diff line number Diff line change @@ -27,3 +27,4 @@ export {
27
27
} from './trace' ;
28
28
export { getDynamicSamplingContextFromClient , getDynamicSamplingContextFromSpan } from './dynamicSamplingContext' ;
29
29
export { setMeasurement } from './measurement' ;
30
+ export { isValidSampleRate } from './sampling' ;
Original file line number Diff line number Diff line change @@ -103,7 +103,7 @@ export function sampleTransaction<T extends Transaction>(
103
103
/**
104
104
* Checks the given sample rate to make sure it is valid type and value (a boolean, or a number between 0 and 1).
105
105
*/
106
- function isValidSampleRate ( rate : unknown ) : boolean {
106
+ export function isValidSampleRate ( rate : unknown ) : boolean {
107
107
// we need to check NaN explicitly because it's of type 'number' and therefore wouldn't get caught by this typecheck
108
108
// eslint-disable-next-line @typescript-eslint/no-explicit-any
109
109
if ( isNaN ( rate ) || ! ( typeof rate === 'number' || typeof rate === 'boolean' ) ) {
You can’t perform that action at this time.
0 commit comments