diff options
Diffstat (limited to 'model/Thread.php')
-rw-r--r-- | model/Thread.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/model/Thread.php b/model/Thread.php index aa48cfd..a9dc690 100644 --- a/model/Thread.php +++ b/model/Thread.php @@ -65,7 +65,7 @@ class Thread { } function get_latest_post($dbc) { - $sql = "SELECT post_id FROM posts WHERE post_thread = " . $this->id . " ORDER BY post_date DESC LIMIT 1"; + $sql = "SELECT post_id FROM posts WHERE post_thread = " . $this->id . " ORDER BY post_date_created DESC LIMIT 1"; $result = mysqli_query($dbc, $sql); if (!$result) { @@ -108,4 +108,4 @@ function get_all_threads($dbc) { mysqli_free_result($result); return $threads; -}
\ No newline at end of file +} |