changeset 14102:a124e80d3498

Merge 13.0->trunk
author Kim Alvefur <zash@zash.se>
date Wed, 11 Mar 2026 16:59:10 +0100
parents b5002c87db0b (current diff) 3e6bb6ffbd43 (diff)
children b5eeb6730721
files core/moduleapi.lua
diffstat 2 files changed, 4 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/core/moduleapi.lua	Sun Mar 08 19:30:54 2026 +0300
+++ b/core/moduleapi.lua	Wed Mar 11 16:59:10 2026 +0100
@@ -407,6 +407,7 @@
 	local options = set.new{default, ...};
 	if not options:contains(value) then
 		self:log("error", "Config option '%s' not in set of allowed values (one of: %s)", name, options);
+		return default;
 	end
 	return value;
 end
--- a/plugins/mod_turn_external.lua	Sun Mar 08 19:30:54 2026 +0300
+++ b/plugins/mod_turn_external.lua	Wed Mar 11 16:59:10 2026 +0100
@@ -33,9 +33,9 @@
 				host = host;
 				port = type == "turns" and tls_port or port;
 
-				username = type == "turn" and user or nil;
-				secret = type == "turn" and secret or nil;
-				ttl = type == "turn" and ttl or nil;
+				username = (type == "turn" or type == "turns") and user or nil;
+				secret = (type == "turn" or type == "turns") and secret or nil;
+				ttl = (type == "turn" or type == "turns") and ttl or nil;
 			})
 		end
 	end