refactor(cloudfunc) getSize: regexp

This commit is contained in:
coderaiser 2019-05-17 14:00:52 +03:00
parent dbbeb063e7
commit 5fb5652f3d

View file

@ -244,7 +244,7 @@ function getSize(file) {
type,
} = file;
if (type === 'directory')
if (/^directory$/.test(type))
return '<dir>';
if (/link/.test(type))