Skip to content

Commit

Permalink
Merge pull request bitpay#1886 from justinkook/fix/createCredentials
Browse files Browse the repository at this point in the history
fixed deprecated crypto functions that was being imported * in encryp…
  • Loading branch information
micahriggan authored Jan 10, 2019
2 parents 90b51f6 + f6b81b9 commit b63a26e
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion packages/bitcore-client/src/encryption.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,11 @@
import * as crypto from 'crypto';
import { createHash, createCipheriv, createDecipheriv, randomBytes } from 'crypto';

const crypto = {
createHash,
createCipheriv,
createDecipheriv,
randomBytes,
}

export function shaHash(data, algo = 'sha256') {
let hash = crypto
Expand Down

0 comments on commit b63a26e

Please sign in to comment.