Browse Source

Fix occ files:scan-app-data elapsed time

Signed-off-by: Joel S <joel.devbox@protonmail.com>
tags/v16.0.0alpha1
Joel S 5 years ago
parent
commit
27aafa77db
2 changed files with 4 additions and 5 deletions
  1. 1
    1
      apps/files/lib/Command/Scan.php
  2. 3
    4
      apps/files/lib/Command/ScanAppData.php

+ 1
- 1
apps/files/lib/Command/Scan.php View File

@@ -291,7 +291,7 @@ class Scan extends Base {
protected function formatExecTime() {
$secs = round($this->execTime);
# convert seconds into HH:MM:SS form
return sprintf('%02d:%02d:%02d', ($secs/3600),($secs/60%60), $secs%60);
return sprintf('%02d:%02d:%02d', ($secs/3600), ($secs/60%60), $secs%60);
}

/**

+ 3
- 4
apps/files/lib/Command/ScanAppData.php View File

@@ -216,10 +216,9 @@ class ScanAppData extends Base {
* @return string
*/
protected function formatExecTime() {
list($secs, ) = explode('.', sprintf("%.1f", $this->execTime));

# if you want to have microseconds add this: . '.' . $tens;
return date('H:i:s', $secs);
$secs = round($this->execTime);
# convert seconds into HH:MM:SS form
return sprintf('%02d:%02d:%02d', ($secs/3600), ($secs/60%60), $secs%60);
}

/**

Loading…
Cancel
Save