[polari/wip/carlosg/tracker: 426/445] lib: Use anonymous nodes to insert messages
- From: Carlos Garnacho <carlosg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [polari/wip/carlosg/tracker: 426/445] lib: Use anonymous nodes to insert messages
- Date: Mon, 21 Jun 2021 22:04:10 +0000 (UTC)
commit e4a84be1235f8b660adbded4a444524736289751
Author: Carlos Garnacho <carlosg gnome org>
Date: Sun Feb 24 22:45:52 2019 +0100
lib: Use anonymous nodes to insert messages
There's no need to generate a UUID URN explicitly, it will also
be done implicitly by the lower layers with better guarantees about
duplicates.
src/lib/polari-message.c | 7 ++-----
1 file changed, 2 insertions(+), 5 deletions(-)
---
diff --git a/src/lib/polari-message.c b/src/lib/polari-message.c
index 945fcf46..b37616a0 100644
--- a/src/lib/polari-message.c
+++ b/src/lib/polari-message.c
@@ -202,11 +202,9 @@ polari_message_to_tracker_resource (PolariMessage *message,
gboolean is_room)
{
TrackerResource *res, *rel;
- char *uri, *time;
+ char *time;
- uri = tracker_sparql_get_uuid_urn ();
-
- res = tracker_resource_new (uri);
+ res = tracker_resource_new (NULL);
if (polari_message_is_action (message))
tracker_resource_set_uri (res, "rdf:type", "polari:ActionMessage");
@@ -226,7 +224,6 @@ polari_message_to_tracker_resource (PolariMessage *message,
rel = create_channel_resource (channel_name, account_id, is_room);
tracker_resource_set_take_relation (res, "polari:channel", rel);
- g_free (uri);
g_free (time);
return res;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]