force cast string

This commit is contained in:
Sayem Chowdhury 2021-04-27 02:10:24 +06:00
parent 629cbdc60c
commit 5f26e7ca90
1 changed files with 1 additions and 1 deletions

View File

@ -3,7 +3,7 @@ import type {trackType} from '../types';
const md5 = (data: string, type: crypto.Encoding = 'ascii') => {
const md5sum = crypto.createHash('md5');
md5sum.update(data, type);
md5sum.update(data.toString(), type);
return md5sum.digest('hex');
};