aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/mod_storage_sql.lua
diff options
context:
space:
mode:
authorMatthew Wild <mwild1@gmail.com>2017-04-30 10:44:53 +0100
committerMatthew Wild <mwild1@gmail.com>2017-04-30 10:44:53 +0100
commitf9ef95d5e6c01b25183a15a236a63077c0593436 (patch)
tree23bf534f97758cd9a0a381256be32d5dfe523472 /plugins/mod_storage_sql.lua
parent8617a1c4c824e3d3ed7d8ca27357625ba2ca2fd7 (diff)
downloadprosody-f9ef95d5e6c01b25183a15a236a63077c0593436.tar.gz
prosody-f9ef95d5e6c01b25183a15a236a63077c0593436.zip
mod_storage_sql: Fix logic error introduced by variable rename in aa9f198cb3c9 (thanks waqas)
Diffstat (limited to 'plugins/mod_storage_sql.lua')
-rw-r--r--plugins/mod_storage_sql.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/plugins/mod_storage_sql.lua b/plugins/mod_storage_sql.lua
index aab43d1f..d4a5f871 100644
--- a/plugins/mod_storage_sql.lua
+++ b/plugins/mod_storage_sql.lua
@@ -33,7 +33,7 @@ local function serialize(value)
return "xml", tostring(value);
elseif t == "table" then
local encoded,err = json.encode(value);
- if value then return "json", encoded; end
+ if encoded then return "json", encoded; end
return nil, err;
end
return nil, "Unhandled value type: "..t;