when removing account, remove its data directory instead of leaving it around

recreating the account would resurface the old messages, certainly not what you'ld expect.
it's about time to just remove the files. we do ask admins to confirm that when
removing through admin interface. it's also in the "mox config account rm" help
output now.

for issue #162 by RobSlgm with feedback from x8x, thanks!
This commit is contained in:
Mechiel Lukkien
2024-05-09 16:26:08 +02:00
parent a2c9cfc55b
commit 30ac690c8f
5 changed files with 18 additions and 2 deletions

View File

@ -2194,7 +2194,7 @@ const account = async (name) => {
formPassword.reset();
}), dom.br(), RoutesEditor('account-specific', transports, config.Routes || [], async (routes) => await client.AccountRoutesSave(name, routes)), dom.br(), dom.h2('Danger'), dom.clickbutton('Remove account', async function click(e) {
e.preventDefault();
if (!window.confirm('Are you sure you want to remove this account?')) {
if (!window.confirm('Are you sure you want to remove this account? All account data, including messages will be removed.')) {
return;
}
await check(e.target, client.AccountRemove(name));