Software /
code /
prosody
Diff
plugins/mod_admin_adhoc.lua @ 8192:4354f556c5db
core.usermanager, various modules: Disconnect other resources on password change (thanks waqas) (fixes #512)
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Fri, 28 Jul 2017 13:15:29 +0200 |
parent | 7045:49e2456bf2ce |
child | 8728:41c959c5c84b |
line wrap: on
line diff
--- a/plugins/mod_admin_adhoc.lua Sun Aug 06 13:27:47 2017 +0200 +++ b/plugins/mod_admin_adhoc.lua Fri Jul 28 13:15:29 2017 +0200 @@ -97,7 +97,7 @@ if module_host ~= host then return { status = "completed", error = { message = "Trying to change the password of a user on " .. host .. " but command was sent to " .. module_host}}; end - if usermanager_user_exists(username, host) and usermanager_set_password(username, fields.password, host) then + if usermanager_user_exists(username, host) and usermanager_set_password(username, fields.password, host, nil) then return { status = "completed", info = "Password successfully changed" }; else return { status = "completed", error = { message = "User does not exist" } };