You are here

private function ManageFilesForm::minified_filesize in Minify JS 8

Helper function to format the minified filesize.

Parameters

stdClass $file:

1 call to ManageFilesForm::minified_filesize()
ManageFilesForm::buildForm in src/Form/ManageFilesForm.php
Form constructor.

File

src/Form/ManageFilesForm.php, line 313

Class

ManageFilesForm
Displays a list of detected javascript files and allows actions to be performed on them

Namespace

Drupal\minifyjs\Form

Code

private function minified_filesize($file) {
  if ($file->minified_uri) {
    if ($file->minified_size > 0) {
      return $this
        ->format_filesize($file->minified_size);
    }
    return 0;
  }
  return '-';
}