1
0
mirror of https://github.com/immich-app/immich.git synced 2025-06-30 05:29:30 +02:00

fix(web) fix test (#1059)

This commit is contained in:
Alex
2022-12-04 22:51:22 -06:00
committed by GitHub
parent 5d140145c1
commit 966d99217a
7 changed files with 35 additions and 17 deletions

View File

@ -39,7 +39,7 @@ export function getBytesWithUnit(bytes: number, maxPrecision = 1): [number, stri
* @returns localized bytes with unit as string
*/
export function asByteUnitString(bytes: number, maxPrecision = 1): string {
const locale = Array.from(navigator.languages);
const locale = Array.from(navigator.language);
const [size, unit] = getBytesWithUnit(bytes, maxPrecision);
return `${size.toLocaleString(locale)} ${unit}`;
}