aboutsummaryrefslogtreecommitdiff
path: root/src/java/com/juick/http/www/UserThread.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/java/com/juick/http/www/UserThread.java')
-rw-r--r--src/java/com/juick/http/www/UserThread.java9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/java/com/juick/http/www/UserThread.java b/src/java/com/juick/http/www/UserThread.java
index 9001bd17..3b315be2 100644
--- a/src/java/com/juick/http/www/UserThread.java
+++ b/src/java/com/juick/http/www/UserThread.java
@@ -114,6 +114,13 @@ public class UserThread {
break;
}
+ String txt;
+ if (!msg.Tags.isEmpty() && msg.Tags.contains("code")) {
+ txt = PageTemplates.formatMessageCode(msg.Text);
+ } else {
+ txt = PageTemplates.formatMessage(msg.Text);
+ }
+
out.println("<ul>");
out.println(" <li id=\"msg-" + mid + "\" class=\"msg msgthread\">");
out.println(" <div class=\"msg-avatar\"><a href=\"/" + msg.User.UName + "/\"><img src=\"//i.juick.com/a/" + msg.User.UID + ".png\" alt=\"" + msg.User.UName + "\"/></a></div>");
@@ -122,7 +129,7 @@ public class UserThread {
if (msg.Place != null) {
out.println(" <div class=\"msg-place\"><a href=\"/places/" + msg.Place.pid + "\">" + msg.Place.name + "</a></div>");
}
- out.println(" <div class=\"msg-txt\">" + PageTemplates.formatMessage(msg.Text) + "</div>");
+ out.println(" <div class=\"msg-txt\">" + txt + "</div>");
if (msg.AttachmentType != null) {
if (msg.AttachmentType.equals("jpg")) {