From b8e044958ca90e25dc698dac8b0e8270195ab14a Mon Sep 17 00:00:00 2001
From: Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
Date: Sun, 29 Sep 2019 15:05:17 +0200
Subject: mod_register_ibr: Add FORM_TYPE as required by XEP-0077 (fixes #1511)

Backport of f90abf142d53 from trunk
---
 plugins/mod_register_ibr.lua | 2 ++
 1 file changed, 2 insertions(+)

(limited to 'plugins')

diff --git a/plugins/mod_register_ibr.lua b/plugins/mod_register_ibr.lua
index bbe7581d..e04e6ecd 100644
--- a/plugins/mod_register_ibr.lua
+++ b/plugins/mod_register_ibr.lua
@@ -25,6 +25,7 @@ end);
 local account_details = module:open_store("account_details");
 
 local field_map = {
+	FORM_TYPE = { name = "FORM_TYPE", type = "hidden", value = "jabber:iq:register" };
 	username = { name = "username", type = "text-single", label = "Username", required = true };
 	password = { name = "password", type = "text-private", label = "Password", required = true };
 	nick = { name = "nick", type = "text-single", label = "Nickname" };
@@ -50,6 +51,7 @@ local registration_form = dataform_new{
 	title = title;
 	instructions = instructions;
 
+	field_map.FORM_TYPE;
 	field_map.username;
 	field_map.password;
 };
-- 
cgit v1.2.3