aboutsummaryrefslogtreecommitdiff
path: root/xmpp-vala/src/module
diff options
context:
space:
mode:
authorfiaxh <git@lightrise.org>2021-10-12 17:54:00 +0200
committerfiaxh <git@lightrise.org>2021-10-12 19:53:22 +0200
commitb71196ef073dc1c49f4e42c0380b553286fe426c (patch)
tree2315ac1c5a2410b290646d9a4a3696e4bd40c5ae /xmpp-vala/src/module
parent9285fd07bf555fdf46954c4adfa58751e44633a3 (diff)
downloaddino-b71196ef073dc1c49f4e42c0380b553286fe426c.tar.gz
dino-b71196ef073dc1c49f4e42c0380b553286fe426c.zip
Fix compiler warnings ('passing argument .. from incompatible pointer type') by passing (non)const argument
Diffstat (limited to 'xmpp-vala/src/module')
-rw-r--r--xmpp-vala/src/module/xep/0191_blocking_command.vala10
1 files changed, 5 insertions, 5 deletions
diff --git a/xmpp-vala/src/module/xep/0191_blocking_command.vala b/xmpp-vala/src/module/xep/0191_blocking_command.vala
index be312581..987f538a 100644
--- a/xmpp-vala/src/module/xep/0191_blocking_command.vala
+++ b/xmpp-vala/src/module/xep/0191_blocking_command.vala
@@ -15,8 +15,8 @@ public class Module : XmppStreamModule, Iq.Handler {
return stream.get_flag(Flag.IDENTITY).blocklist.contains(jid);
}
- public bool block(XmppStream stream, Gee.List<string> jids) {
- if (jids.size == 0) return false; // This would otherwise be a bad-request error.
+ public bool block(XmppStream stream, string[] jids) {
+ if (jids.length == 0) return false; // This would otherwise be a bad-request error.
StanzaNode block_node = new StanzaNode.build("block", NS_URI).add_self_xmlns();
fill_node_with_items(block_node, jids);
@@ -25,8 +25,8 @@ public class Module : XmppStreamModule, Iq.Handler {
return true;
}
- public bool unblock(XmppStream stream, Gee.List<string> jids) {
- if (jids.size == 0) return false; // This would otherwise unblock all blocked JIDs.
+ public bool unblock(XmppStream stream, string[] jids) {
+ if (jids.length == 0) return false; // This would otherwise unblock all blocked JIDs.
StanzaNode unblock_node = new StanzaNode.build("unblock", NS_URI).add_self_xmlns();
fill_node_with_items(unblock_node, jids);
@@ -112,7 +112,7 @@ public class Module : XmppStreamModule, Iq.Handler {
return jids;
}
- private void fill_node_with_items(StanzaNode node, Gee.List<string> jids) {
+ private void fill_node_with_items(StanzaNode node, string[] jids) {
foreach (string jid in jids) {
StanzaNode item_node = new StanzaNode.build("item", NS_URI).add_self_xmlns();
item_node.set_attribute("jid", jid, NS_URI);