Skip to content

Commit 9df6b69

Browse files
authored
Merge pull request #179 from lifeiscontent/patch-1
Update base64.ts
2 parents df91b05 + 09fde58 commit 9df6b69

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

base64.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -215,7 +215,7 @@ const decode = (src: string) => _decode(_unURI(src));
215215
* check if a value is a valid Base64 string
216216
* @param {String} src a value to check
217217
*/
218-
const isValid = (src: any) => {
218+
const isValid = (src: unknown) => {
219219
if (typeof src !== 'string') return false;
220220
const s = src.replace(/\s+/g, '').replace(/={0,2}$/, '');
221221
return !/[^\s0-9a-zA-Z\+/]/.test(s) || !/[^\s0-9a-zA-Z\-_]/.test(s);

0 commit comments

Comments
 (0)