Skip to content

Commit

Permalink
fix: remove declare globalThis crypto
Browse files Browse the repository at this point in the history
  • Loading branch information
elegantcoder committed Jan 9, 2024
1 parent 7119e0b commit b5b80eb
Showing 1 changed file with 1 addition and 8 deletions.
9 changes: 1 addition & 8 deletions src/crypto-util/crypto-util.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,6 @@
import type { webcrypto } from 'crypto';

declare global {
namespace globalThis {
// eslint-disable-next-line no-var
var crypto: typeof webcrypto;
}
}

const crypto = globalThis.crypto;
const crypto = (globalThis as any).crypto as typeof webcrypto;

export namespace CryptoUtil {
export const sha256 = async (data: string | Uint8Array): Promise<Uint8Array> => {
Expand Down

0 comments on commit b5b80eb

Please sign in to comment.