mirror of
https://git.sekbaer.de/Friendica/friendica.git
synced 2025-06-17 04:15:15 +02:00
formatBytes calls
implement function in new class
This commit is contained in:
parent
b73af72deb
commit
46d7767fd0
5 changed files with 8 additions and 6 deletions
|
@ -11,6 +11,7 @@ use Friendica\Database\DBA;
|
|||
use Friendica\Model\Contact;
|
||||
use Friendica\Util\DateTimeFormat;
|
||||
use Friendica\Util\Mimetype;
|
||||
use Friendica\Util\Strings;
|
||||
|
||||
function wall_attach_post(App $a) {
|
||||
|
||||
|
@ -115,7 +116,7 @@ function wall_attach_post(App $a) {
|
|||
}
|
||||
|
||||
if ($maxfilesize && $filesize > $maxfilesize) {
|
||||
$msg = L10n::t('File exceeds size limit of %s', formatBytes($maxfilesize));
|
||||
$msg = L10n::t('File exceeds size limit of %s', Strings::formatBytes($maxfilesize));
|
||||
if ($r_json) {
|
||||
echo json_encode(['error' => $msg]);
|
||||
} else {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue