Skip to content

Commit

Permalink
Merge pull request #7 from managed-components/fix-stub-node20
Browse files Browse the repository at this point in the history
Only stub crypto if it's not globally available
  • Loading branch information
jonnyparris authored Dec 11, 2023
2 parents 89b1e18 + 3fff278 commit b14a2ad
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/index.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,9 @@ import {
getDeleteProfileEventArgs,
} from '.'

vi.stubGlobal('crypto', crypto)
if (!global.crypto) {
vi.stubGlobal('crypto', crypto)
}

const settings = {
token: '12345',
Expand Down

0 comments on commit b14a2ad

Please sign in to comment.