From 7a272b16703fd26c19f6f2519229b1ca539377ed Mon Sep 17 00:00:00 2001 From: Kim Alvefur Date: Mon, 25 Oct 2021 21:45:06 +0200 Subject: mod_http_file_share: Move number coercion into util.dataforms --- plugins/mod_http_file_share.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'plugins/mod_http_file_share.lua') diff --git a/plugins/mod_http_file_share.lua b/plugins/mod_http_file_share.lua index 7b05c85a..a5ac287c 100644 --- a/plugins/mod_http_file_share.lua +++ b/plugins/mod_http_file_share.lua @@ -47,8 +47,8 @@ end module:add_extension(dataform { { name = "FORM_TYPE", type = "hidden", value = namespace }, - { name = "max-file-size", type = "text-single" }, -}:form({ ["max-file-size"] = tostring(file_size_limit) }, "result")); + { name = "max-file-size", type = "text-single", datatype = "xs:integer" }, +}:form({ ["max-file-size"] = file_size_limit }, "result")); local upload_errors = errors.init(module.name, namespace, { access = { type = "auth"; condition = "forbidden" }; -- cgit v1.2.3