All files / src/md5 md5.ts

44.44% Statements 4/9
0% Branches 0/6
0% Functions 0/1
50% Lines 3/6

Press n or j to go to the next uncovered block, b, p or k for the previous block.

1 2 3 4 5 6 7 8 9 10 111x   1x   1x            
import * as R from 'ramda';
//@ts-ignore
import md5 from "../_internal/jsMD5";
 
export const getMD5 = (md5Key: any): string => {
  if (R.isEmpty(md5Key) || R.isNil(md5Key)) return md5Key;
 
  if (R.is(String, md5Key)) return md5(md5Key);
 
  return md5Key;
}