@bbl-digital/snorre 4.0.6 → 4.0.7
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/bundle.js +1 -1
- package/esm/utils/file.js +1 -1
- package/lib/utils/file.js +1 -1
- package/package.json +1 -1
package/dist/bundle.js
CHANGED
@@ -26769,7 +26769,7 @@
|
|
26769
26769
|
|
26770
26770
|
const formatBytes = bytes => {
|
26771
26771
|
if (!bytes || bytes === 0) return '0 KB';
|
26772
|
-
const k =
|
26772
|
+
const k = 1000;
|
26773
26773
|
const sizes = ['Bytes', 'KB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB'];
|
26774
26774
|
const i = Math.floor(Math.log(bytes) / Math.log(k));
|
26775
26775
|
return parseFloat((bytes / Math.pow(k, i)).toFixed(2)) + ' ' + sizes[i];
|
package/esm/utils/file.js
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
export const formatBytes = bytes => {
|
2
2
|
if (!bytes || bytes === 0) return '0 KB';
|
3
|
-
const k =
|
3
|
+
const k = 1000;
|
4
4
|
const sizes = ['Bytes', 'KB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB'];
|
5
5
|
const i = Math.floor(Math.log(bytes) / Math.log(k));
|
6
6
|
return parseFloat((bytes / Math.pow(k, i)).toFixed(2)) + ' ' + sizes[i];
|
package/lib/utils/file.js
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
export const formatBytes = bytes => {
|
2
2
|
if (!bytes || bytes === 0) return '0 KB';
|
3
|
-
const k =
|
3
|
+
const k = 1000;
|
4
4
|
const sizes = ['Bytes', 'KB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB'];
|
5
5
|
const i = Math.floor(Math.log(bytes) / Math.log(k));
|
6
6
|
return parseFloat((bytes / Math.pow(k, i)).toFixed(2)) + ' ' + sizes[i];
|