Skip to content

Commit 987de11

Browse files
committed
Added note and changed category in migration guide
1 parent 8db09bb commit 987de11

File tree

2 files changed

+14
-9
lines changed

2 files changed

+14
-9
lines changed

docs/en/appendices/5-4-migration-guide.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -14,15 +14,6 @@ automating some of the migration work. Run rector before updating your
1414
bin/cake upgrade rector --rules cakephp54 <path/to/app/src>
1515
```
1616

17-
## Breaking Changes
18-
19-
- `Number::toReadableSize()` now calculates decimal units (KB, MB, GB and TB)
20-
using an exponent of ten, meaning that 1 KB is 1000 Bytes. The units from the
21-
previous calculation method, where 1024 Bytes equaled 1 KB, have been changed
22-
to KiB, MiB, GiB, and TiB as defined in ISO/IEC 80000-13. It is possible to
23-
switch between the two units using a new optional boolean parameter in
24-
`Number::toReadableSize()`, as well as the new global setter `Number::setUseIecUnits()`.
25-
2617
## Behavior Changes
2718

2819
- WIP
@@ -33,6 +24,15 @@ switch between the two units using a new optional boolean parameter in
3324

3425
## New Features
3526

27+
### I18n
28+
29+
- `Number::toReadableSize()` now calculates decimal units (KB, MB, GB and TB)
30+
using an exponent of ten, meaning that 1 KB is 1000 Bytes. The units from the
31+
previous calculation method, where 1024 Bytes equaled 1 KB, have been changed
32+
to KiB, MiB, GiB, and TiB as defined in ISO/IEC 80000-13. It is possible to
33+
switch between the two units using a new optional boolean parameter in
34+
`Number::toReadableSize()`, as well as the new global setter `Number::setUseIecUnits()`.
35+
3636
### Utility
3737

3838
- New `Cake\Utility\Fs\Finder` class provides a fluent, iterator-based API for

docs/en/core-libraries/number.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,11 @@ This mean that:
205205
- 1000 Bytes = 1 KB
206206
- 1024 Bytes = 1 KiB
207207

208+
::: info Added in version 5.4.0
209+
It is now possible to use the byte units defined by the ISO/IEC 80000-13
210+
standard alongside more natural decimal units.
211+
:::
212+
208213
## Setting the Default Byte Units
209214

210215
### Number::setUseIecUnits()

0 commit comments

Comments
 (0)