Browse Source

Fix 'dateAdded()' getter (#2774)

Be homogeneous in field used, to prevent weird behavior in the future.
Julien-Pierre Avérous 6 years ago
parent
commit
f3ff4a59e6
1 changed files with 2 additions and 2 deletions
  1. 2 2
      app/Models/Entry.php

+ 2 - 2
app/Models/Entry.php

@@ -74,10 +74,10 @@ class FreshRSS_Entry extends Minz_Model {
 			if ($microsecond) {
 				return $this->date_added;
 			} else {
-				return intval(substr($this->id, 0, -6));
+				return intval(substr($this->date_added, 0, -6));
 			}
 		} else {
-			$date = intval(substr($this->id, 0, -6));
+			$date = intval(substr($this->date_added, 0, -6));
 			return timestamptodate($date);
 		}
 	}