Diff

util/pubsub.lua @ 8212:66173e4b355a

util.pubsub: Add the publisher as an attribute in the item element. This makes the backend able to obtain the publisher without changing the API.
author Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
date Sun, 02 Apr 2017 19:08:54 +0100
parent 8211:5cbbe825d9d1
child 8217:5f4e0d67b82a
line wrap: on
line diff
--- a/util/pubsub.lua	Sun Apr 02 19:08:54 2017 +0100
+++ b/util/pubsub.lua	Sun Apr 02 19:08:54 2017 +0100
@@ -268,6 +268,7 @@
 		node_obj = self.nodes[node];
 	end
 	local node_data = self.data[node];
+	item.attr.publisher = actor;
 	local ok = node_data:set(id, item);
 	if not ok then
 		return nil, "internal-server-error";