diff --git a/ajax/getfoldercontents.php b/ajax/getfoldercontents.php
index 060e744..ba0e2a3 100644
--- a/ajax/getfoldercontents.php
+++ b/ajax/getfoldercontents.php
@@ -69,7 +69,7 @@ foreach ( $entries as $entry ) {
if ( is_dir($fullcompath . $entry) ) {
$info["comname"] = (strpos($entry, " - ") !== false) ? str_replace(" - ", "
", $entry) : $entry;
$info["newpath"] = $compath . (($compath == "/") ? "" : "/") . $entry;
- $info["mtime"] = filemtime($fullcompath . $entry);
+ if ( $_SESSION["sortorder"] == SORTBYDATE ) $info["mtime"] = filemtime($fullcompath . $entry);
//$info["thumburl"] = htmlentities(THUMBSDIR . $compath . (($compath == "/") ? "" : "/") . $entry, ENT_QUOTES) . ".jpg";
$info["thumburl"] = THUMBSDIR . $compath . (($compath == "/") ? "" : "/") . $entry . ".jpg";
if ( isset($comics_read[$entry]) ) {
@@ -96,7 +96,7 @@ foreach ( $entries as $entry ) {
}
//$info["comname"] = substr(((strpos($entry, " - ") !== false) ? str_replace(" - ", "
", $entry) : $entry), 0, -4);
$info["relcomic"] = base64_encode($compath . (($compath == "/") ? "" : "/") . $entry);
- $info["mtime"] = filemtime($fullcompath . $entry);
+ if ( $_SESSION["sortorder"] == SORTBYDATE ) $info["mtime"] = filemtime($fullcompath . $entry);
$info["thumburl"] = THUMBSDIR . $compath . (($compath == "/") ? "" : "/") . $withoutext . ".jpg";
if ( isset($issues_read[$entry]) ) {
$info["read"] = true;