Forum

Ask, reply and learn. Join the community of Akaunting.

New Discussion

ReadableSize Error When Viewing Bills with Attachments

Scott Carson   ( User )

Commented 10 months ago

Whenever I try to view a bill (and some transactions), I get this error:

Plank\Mediable\Helpers\File::readableSize(): Argument #1 ($bytes) must be of type int, string given, called in public_html/akaunting3/vendor/plank/laravel-mediable/src/Media.php on line 308 (View: public_html/akaunting3/resources/views/components/media/file.blade.php) (View: public_html/akaunting3/resources/views/components/media/file.blade.php) (View: public_html/akaunting3/resources/views/components/media/file.blade.php) (View: public_html/akaunting3/resources/views/components/media/file.blade.php)

My team has tracked the error down to this file, where we commented out the file size output:

/public_html/akaunting3/resources/views/components/media/file.blade.php

Specifically, change this:


{{ $file->readableSize() }}

... to this:

{{-- $file->readableSize() --}}


Obviously not an upgrade-proof solution, but basically we just commented it out as there seems to be a dependency missing or something when reading file size of PDFs.

Can anybody tell me what additional PHP extensions are required?

Note: After upgrading to 3.0.15, the problem persists.

Please login or register to leave a response.

Showing 1 to 1 of 1 discussions