if count == 0 then
local stmt = assert(connection:prepare("CREATE TABLE `Prosody` (`host` TEXT, `user` TEXT, `store` TEXT, `key` TEXT, `subkey` TEXT, `type` TEXT, `value` TEXT);"));
assert(stmt:execute());
- assert(connection:commit());
module:log("debug", "Initialized new SQLite3 database");
end
+ assert(connection:commit());
--print("===", json.stringify())
end
end
end
end
end
- return haveany and result or nil;
+ return commit(haveany and result or nil);
end
function keyval_store:set(username, data)
user,store = username,self.store;
end
end
end
- return haveany and result or nil;
+ return commit(haveany and result or nil);
end
function map_store:set(username, key, data)
user,store = username,self.store;