aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/mod_storage_sql2.lua
diff options
context:
space:
mode:
authorMatthew Wild <mwild1@gmail.com>2013-06-24 18:29:04 +0100
committerMatthew Wild <mwild1@gmail.com>2013-06-24 18:29:04 +0100
commitceb0343e1ba7647ae4feb5048613a76edb0057ca (patch)
tree76ea4bc5aa6f15cd5c7b6d0ad0abda58e1671a4b /plugins/mod_storage_sql2.lua
parentd6d5f55ac45238560bb9892a2c52e842eea8b6ab (diff)
parent4b575092a1185c4a0a951e0515fbae6f798c3ef3 (diff)
downloadprosody-ceb0343e1ba7647ae4feb5048613a76edb0057ca.tar.gz
prosody-ceb0343e1ba7647ae4feb5048613a76edb0057ca.zip
Merge 0.9->trunk
Diffstat (limited to 'plugins/mod_storage_sql2.lua')
-rw-r--r--plugins/mod_storage_sql2.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/plugins/mod_storage_sql2.lua b/plugins/mod_storage_sql2.lua
index 7d705b0b..382c0e23 100644
--- a/plugins/mod_storage_sql2.lua
+++ b/plugins/mod_storage_sql2.lua
@@ -85,7 +85,7 @@ local function set_encoding()
module:log("warn", "Found %d columns in prosody table requiring encoding change, updating now...", n_bad_columns);
local fix_column_query1 = "ALTER TABLE `prosody` CHANGE `%s` `%s` BLOB;";
local fix_column_query2 = "ALTER TABLE `prosody` CHANGE `%s` `%s` %s CHARACTER SET 'utf8' COLLATE 'utf8_bin';";
- for row in success:rows() do
+ for row in result:rows() do
local column_name, column_type = unpack(row);
engine:execute(fix_column_query1:format(column_name, column_name));
engine:execute(fix_column_query2:format(column_name, column_name, column_type));