From b0264b3e0034ddd9ea76d0e13bb4c3c709ba3b3e Mon Sep 17 00:00:00 2001 From: fiaxh Date: Sat, 12 Aug 2017 23:27:20 +0200 Subject: xmpp-vala: Remove require-functions --- plugins/http-files/src/upload_stream_module.vala | 6 ------ plugins/omemo/src/stream_module.vala | 2 -- plugins/openpgp/src/stream_module.vala | 2 -- 3 files changed, 10 deletions(-) (limited to 'plugins') diff --git a/plugins/http-files/src/upload_stream_module.vala b/plugins/http-files/src/upload_stream_module.vala index 573f298a..2e697afa 100644 --- a/plugins/http-files/src/upload_stream_module.vala +++ b/plugins/http-files/src/upload_stream_module.vala @@ -75,8 +75,6 @@ public class UploadStreamModule : XmppStreamModule { } public override void attach(XmppStream stream) { - Iq.Module.require(stream); - ServiceDiscovery.Module.require(stream); stream.stream_negotiated.connect(query_availability); } @@ -84,10 +82,6 @@ public class UploadStreamModule : XmppStreamModule { stream.get_module(Bind.Module.IDENTITY).bound_to_resource.disconnect(query_availability); } - public static void require(XmppStream stream) { - if (stream.get_module(IDENTITY) == null) stream.add_module(new ChatMarkers.Module()); - } - public override string get_ns() { return NS_URI; } public override string get_id() { return IDENTITY.id; } diff --git a/plugins/omemo/src/stream_module.vala b/plugins/omemo/src/stream_module.vala index f6ba82e6..4fdf85a7 100644 --- a/plugins/omemo/src/stream_module.vala +++ b/plugins/omemo/src/stream_module.vala @@ -112,8 +112,6 @@ public class StreamModule : XmppStreamModule { } public override void attach(XmppStream stream) { - Message.Module.require(stream); - Pubsub.Module.require(stream); if (!Plugin.ensure_context()) return; this.store = Plugin.get_context().create_store(); diff --git a/plugins/openpgp/src/stream_module.vala b/plugins/openpgp/src/stream_module.vala index b9742624..745f2005 100644 --- a/plugins/openpgp/src/stream_module.vala +++ b/plugins/openpgp/src/stream_module.vala @@ -49,10 +49,8 @@ namespace Dino.Plugins.OpenPgp { } public override void attach(XmppStream stream) { - Presence.Module.require(stream); stream.get_module(Presence.Module.IDENTITY).received_presence.connect(on_received_presence); stream.get_module(Presence.Module.IDENTITY).pre_send_presence_stanza.connect(on_pre_send_presence_stanza); - Message.Module.require(stream); stream.get_module(Message.Module.IDENTITY).pre_received_message.connect(on_pre_received_message); stream.add_flag(new Flag()); } -- cgit v1.2.3-70-g09d2