Skip to content

Commit 7fd91eb

Browse files
committed
Update README
1 parent a8e565a commit 7fd91eb

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

README.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ A variety of file size strings are supported here as well.
3737
echo $size->as('megabytes'); // 512000
3838
```
3939

40-
The second argument specifies decimal precision (default is 2).
40+
The second argument specifies decimal precision (default is `2`).
4141

4242
```php
4343
echo $size->as('TB', 3); // 0.488
@@ -79,7 +79,7 @@ $size->add('2G')
7979
->multiplyBy(4)
8080
->divideBy(2);
8181

82-
echo $size->asAuto(); // '10.00 GB'
82+
echo $size; // '10.00 GB'
8383
```
8484

8585
Negative values are supported. In the case below, 1.2 megabytes are subtracted:
@@ -101,7 +101,7 @@ The second argument of the constructor is the number base, which accepts either
101101
```php
102102
$size = new FileSize(10921134, 10);
103103

104-
echo $size->asAuto(); // '10.92 MB'
104+
echo $size; // '10.92 MB'
105105
```
106106

107107
### Decimal separator
@@ -111,5 +111,5 @@ The third argument of the constructor is the decimal separator, which is a perio
111111
```php
112112
$size = new FileSize('1.234.522.678,12 KB', 2, ',');
113113

114-
echo $size->asAuto(); // '1,15 TB'
114+
echo $size; // '1,15 TB'
115115
```

0 commit comments

Comments
 (0)