diff options
author | Waqas Hussain <waqas20@gmail.com> | 2011-01-05 06:26:49 +0500 |
---|---|---|
committer | Waqas Hussain <waqas20@gmail.com> | 2011-01-05 06:26:49 +0500 |
commit | 24171721b5bdb6a110e530a3efbfac6148debf24 (patch) | |
tree | ab86f1a757a32afa700bab99f09924a2d0e6d102 | |
parent | e7e865057dc7feffab3d5c46b0f01ff89d289ca2 (diff) | |
download | prosody-24171721b5bdb6a110e530a3efbfac6148debf24.tar.gz prosody-24171721b5bdb6a110e530a3efbfac6148debf24.zip |
net.httpserver: Changed an unnecessary global access.
-rw-r--r-- | net/httpserver.lua | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/httpserver.lua b/net/httpserver.lua index 4be62ced..6fd9b65e 100644 --- a/net/httpserver.lua +++ b/net/httpserver.lua @@ -20,7 +20,7 @@ local t_insert, t_concat = table.insert, table.concat; local s_match, s_gmatch = string.match, string.gmatch; local tonumber, tostring, pairs, ipairs, type = tonumber, tostring, pairs, ipairs, type; -local urlencode = function (s) return s and (s:gsub("%W", function (c) return string.format("%%%02x", c:byte()); end)); end +local urlencode = function (s) return s and (s:gsub("%W", function (c) return ("%%%02x"):format(c:byte()); end)); end local log = require "util.logger".init("httpserver"); |