mirror of
https://github.com/sigoden/dufs.git
synced 2026-04-09 00:59:02 +03:00
fix: webui formatDirSize (#568)
This commit is contained in:
@@ -881,8 +881,8 @@ function padZero(value, size) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function formatDirSize(size) {
|
function formatDirSize(size) {
|
||||||
const unit = file.size === 1 ? "item" : "items";
|
const unit = size === 1 ? "item" : "items";
|
||||||
const num = size >= MAX_SUBPATHS_COUNT ? `>${MAX_SUBPATHS_COUNT - 1}` : `${file.size}`;
|
const num = size >= MAX_SUBPATHS_COUNT ? `>${MAX_SUBPATHS_COUNT - 1}` : `${size}`;
|
||||||
return ` ${num} ${unit}`;
|
return ` ${num} ${unit}`;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user