aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2021-04-05 17:15:12 +0200
committerKim Alvefur <zash@zash.se>2021-04-05 17:15:12 +0200
commitbb06c42b0793e9860ec7b2a7259f7065826c95ab (patch)
tree1af064348f3e2c08090f8c78f4d92332455a0116
parentf7131f81f25b7407a0c31a337305306b615fe33f (diff)
downloadprosody-bb06c42b0793e9860ec7b2a7259f7065826c95ab.tar.gz
prosody-bb06c42b0793e9860ec7b2a7259f7065826c95ab.zip
mod_http_file_share: Group related properties for readability
-rw-r--r--plugins/mod_http_file_share.lua8
1 files changed, 6 insertions, 2 deletions
diff --git a/plugins/mod_http_file_share.lua b/plugins/mod_http_file_share.lua
index 60b26ff3..d082bee7 100644
--- a/plugins/mod_http_file_share.lua
+++ b/plugins/mod_http_file_share.lua
@@ -134,12 +134,16 @@ end
function get_authz(slot, uploader, filename, filesize, filetype)
return jwt.sign(secret, {
+ -- token properties
sub = uploader;
+ exp = os.time()+300;
+
+ -- slot properties
+ slot = slot;
+ -- file properties
filename = filename;
filesize = filesize;
filetype = filetype;
- slot = slot;
- exp = os.time()+300;
});
end