summaryrefslogtreecommitdiff
path: root/themes/default
diff options
context:
space:
mode:
authorBharat Mediratta <bharat@menalto.com>2008-12-31 07:22:35 +0000
committerBharat Mediratta <bharat@menalto.com>2008-12-31 07:22:35 +0000
commitfc56ebd4346b1e4515388ec8570f26deea7fd500 (patch)
tree7fe58e733a087b934c2a3aefc02076edd6724844 /themes/default
parent77bb22a65c64bd5bae1a304051e1e19bd3993b52 (diff)
Simplify the next/previous logic in the theme by passing in a null
next/prev sib if one didn't exist. (that's what we were supposed to be doing in the first place, anyway)
Diffstat (limited to 'themes/default')
-rw-r--r--themes/default/views/photo.html.php5
1 files changed, 3 insertions, 2 deletions
diff --git a/themes/default/views/photo.html.php b/themes/default/views/photo.html.php
index d23dec2d..9af66c35 100644
--- a/themes/default/views/photo.html.php
+++ b/themes/default/views/photo.html.php
@@ -13,12 +13,13 @@
<?= $theme->photo_bottom() ?>
</div>
-<? if ($position > 1): ?>
+<? if ($previous_item): ?>
<a href="<?= $previous_item->url() ?>"><?= _("previous") ?></a>
<? endif ?>
+
<?= sprintf(_("Viewing photo %d of %d"), $position, $sibling_count) ?>
-<? if ($position < $sibling_count): ?>
+<? if ($next_item): ?>
<a href="<?= $next_item->url() ?>"><?= _("next") ?></a>
<? endif ?>