]> git.bts.cx Git - garden.git/blobdiff - garden.php
Some small template fixes
[garden.git] / garden.php
index 6035ee8dde8192d670e60058f0b082b9d2700f09..8c0127705962891ee05cda45655bfa0539462977 100644 (file)
@@ -529,7 +529,14 @@ function garden_generate_atom($output_directory, $output_filename, $content_item
                        continue;
                }
 
-               $recent_items[$item->date] = $item;
+               $date_key = $item->date;
+
+               // Hack to support sorting without missing entries
+               while (isset($recent_items[$date_key])) {
+                       $date_key += 1;
+               }
+
+               $recent_items[$date_key] = $item;
        }
 
        // Sort by date...