From: David ‘Bombe’ Roden Date: Sun, 5 Dec 2010 12:36:57 +0000 (+0100) Subject: Don’t try to show unknown posts. X-Git-Tag: 0.3.2-RC5~2 X-Git-Url: https://git.pterodactylus.net/?a=commitdiff_plain;h=12b8072e2d1f84e5ada9418493d27ceba481206c;p=Sone.git Don’t try to show unknown posts. --- diff --git a/src/main/resources/i18n/sone.en.properties b/src/main/resources/i18n/sone.en.properties index 32ff6c6..d0c44f5 100644 --- a/src/main/resources/i18n/sone.en.properties +++ b/src/main/resources/i18n/sone.en.properties @@ -95,6 +95,8 @@ Page.ViewSone.PostList.Text.NoPostYet=This Sone has not yet posted anything. Page.ViewPost.Title=View Post - Sone Page.ViewPost.Page.Title=View Post by {sone} +Page.ViewPost.Page.TitleUnknownSone=View Unknown Post +Page.ViewPost.Text.UnknownPost=This post has not yet been downloaded. Page.Like.Title=Like Post - Sone Page.Unlike.Title=Unlike Post - Sone diff --git a/src/main/resources/templates/viewPost.html b/src/main/resources/templates/viewPost.html index 3de8ebc..a61f858 100644 --- a/src/main/resources/templates/viewPost.html +++ b/src/main/resources/templates/viewPost.html @@ -3,8 +3,14 @@ -

<%= Page.ViewPost.Page.Title|l10n|insert needle="{sone}" key=post.sone.niceName|html>

+ <%ifnull post.sone> +

<%= Page.ViewPost.Page.TitleUnknownSone|l10n|html>

- <%include include/viewPost.html> +

<%= Page.ViewPost.Text.UnknownPost|l10n|html>

+ <%else> +

<%= Page.ViewPost.Page.Title|l10n|insert needle="{sone}" key=post.sone.niceName|html>

+ + <%include include/viewPost.html> + <%/if> <%include include/tail.html>