Browse Source

on gere le temps des fichiers plus propres

master
Cabillot Julien 5 years ago
parent
commit
23b85bbe4d
1 changed files with 1 additions and 2 deletions
  1. 3
      lib/Download.php

3
lib/Download.php

@ -176,13 +176,12 @@ class Download {
static function listByState($state)
{
$tmpDT = new DateTime();
$db = DbMongo::get();
$coll = $db->download;
$retour = [];
foreach ($coll->find(['cstate' => $state]) as $element) {
$element['time'] = $tmpDT->setTimestamp($element['timestamp']);
$element['time'] = DateTime::createFromFormat('U', $element['timestamp']);
if (file_exists(DOWNLOADEDDIR.DIRECTORY_SEPARATOR.$element['filename'])) {
$element['href'] = true;

Loading…
Cancel
Save