changeset 4120:d3c7be9e36d9

mod_invites_register: Fix traceback on registration via other module (thanks franck)
author Kim Alvefur <zash@zash.se>
date Mon, 14 Sep 2020 15:55:29 +0200
parents 559ca8d93302
children ee8e7f5196b4
files mod_invites_register/mod_invites_register.lua
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/mod_invites_register/mod_invites_register.lua	Mon Sep 14 14:19:19 2020 +0100
+++ b/mod_invites_register/mod_invites_register.lua	Mon Sep 14 15:55:29 2020 +0200
@@ -90,7 +90,7 @@
 		event.reason = "Registration on this server is through invitation only";
 		return;
 	end
-	if validated_invite.additional_data and validated_invite.additional_data.allow_reset then
+	if validated_invite and validated_invite.additional_data and validated_invite.additional_data.allow_reset then
 		event.allow_reset = validated_invite.additional_data.allow_reset;
 	end
 end);