From 8fbb593a0292420f02c5efad30347e7076abe581 Mon Sep 17 00:00:00 2001 From: =?utf8?q?David=20=E2=80=98Bombe=E2=80=99=20Roden?= Date: Sun, 14 Nov 2010 11:07:32 +0100 Subject: [PATCH] Store the client name and version in the inserted Sone. --- src/main/java/net/pterodactylus/sone/core/SoneInserter.java | 2 ++ src/main/resources/templates/insert/sone.xml | 5 +++++ 2 files changed, 7 insertions(+) diff --git a/src/main/java/net/pterodactylus/sone/core/SoneInserter.java b/src/main/java/net/pterodactylus/sone/core/SoneInserter.java index 86ea92a..e23d1a9 100644 --- a/src/main/java/net/pterodactylus/sone/core/SoneInserter.java +++ b/src/main/java/net/pterodactylus/sone/core/SoneInserter.java @@ -32,6 +32,7 @@ import net.pterodactylus.sone.data.Post; import net.pterodactylus.sone.data.Reply; import net.pterodactylus.sone.data.Sone; import net.pterodactylus.sone.freenet.StringBucket; +import net.pterodactylus.sone.main.SonePlugin; import net.pterodactylus.util.io.Closer; import net.pterodactylus.util.logging.Logging; import net.pterodactylus.util.service.AbstractService; @@ -314,6 +315,7 @@ public class SoneInserter extends AbstractService { } template.set("currentSone", soneProperties); + template.set("version", SonePlugin.VERSION); StringWriter writer = new StringWriter(); StringBucket bucket = null; try { diff --git a/src/main/resources/templates/insert/sone.xml b/src/main/resources/templates/insert/sone.xml index b947dc4..d6dd643 100644 --- a/src/main/resources/templates/insert/sone.xml +++ b/src/main/resources/templates/insert/sone.xml @@ -3,6 +3,11 @@ + + Sone + <% version|xml> + + <% currentSone.profile.firstName|xml> <% currentSone.profile.middleName|xml> -- 2.7.4