aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/java/eu/siacs/conversations/generator
diff options
context:
space:
mode:
authorSam Whited <sam@samwhited.com>2014-11-06 14:33:13 -0500
committerSam Whited <sam@samwhited.com>2014-11-09 07:00:40 -0500
commitbf9207456e7523c2d18f1f9fa007542b5d0e10ea (patch)
tree3a2096ebb66e312d76a713a6b1c2ac9d59b20ef0 /src/main/java/eu/siacs/conversations/generator
parentf15900426d4713b48eb96e0ad0b1cdda5a86becf (diff)
Update another chunk of stuff to use JID objects
Diffstat (limited to 'src/main/java/eu/siacs/conversations/generator')
-rw-r--r--src/main/java/eu/siacs/conversations/generator/MessageGenerator.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/main/java/eu/siacs/conversations/generator/MessageGenerator.java b/src/main/java/eu/siacs/conversations/generator/MessageGenerator.java
index d53346b0..6f076e01 100644
--- a/src/main/java/eu/siacs/conversations/generator/MessageGenerator.java
+++ b/src/main/java/eu/siacs/conversations/generator/MessageGenerator.java
@@ -114,7 +114,7 @@ public class MessageGenerator extends AbstractGenerator {
private MessagePacket generateError(MessagePacket origin) {
MessagePacket packet = new MessagePacket();
packet.setId(origin.getId());
- packet.setAttribute("to", origin.getFrom());
+ packet.setTo(origin.getFrom());
packet.setBody(origin.getBody());
packet.setType(MessagePacket.TYPE_ERROR);
return packet;
@@ -170,7 +170,7 @@ public class MessageGenerator extends AbstractGenerator {
MessagePacket originalMessage, String namespace) {
MessagePacket receivedPacket = new MessagePacket();
receivedPacket.setType(MessagePacket.TYPE_NORMAL);
- receivedPacket.setAttribute("to", originalMessage.getFrom());
+ receivedPacket.setTo(originalMessage.getFrom());
receivedPacket.setFrom(account.getFullJid());
Element received = receivedPacket.addChild("received", namespace);
received.setAttribute("id", originalMessage.getId());