Mercurial > hg > mgallery
diff mgtool.php @ 108:417cdd9f8864
Use image file base name for sorting if timestamps are not available.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Sat, 29 Oct 2016 20:28:52 +0300 |
parents | 121613e40d87 |
children | 9da8bab49711 |
line wrap: on
line diff
--- a/mgtool.php Thu Oct 06 13:43:43 2016 +0300 +++ b/mgtool.php Sat Oct 29 20:28:52 2016 +0300 @@ -358,6 +358,9 @@ if (isset($a["datetime"]) && isset($b["datetime"])) return strcmp($b["datetime"], $a["datetime"]); else + if (isset($a["base"]) && isset($b["base"])) + return strcmp($b["base"], $a["base"]); + else return 0; }