error messages
This commit is contained in:
parent
b3ad640db8
commit
3966da0303
@ -82,4 +82,11 @@ The commands `{alreadyDisabled}` were already disabled.
|
||||
|
||||
// Settings
|
||||
[COMMAND_MODERATION_HELP]
|
||||
Configure moderation related settings.
|
||||
Configure moderation related settings.
|
||||
|
||||
[COMMAND_IMPORT_HELP]
|
||||
Import configuration and data from old versions of the bot.
|
||||
|
||||
[COMMAND_IMPORT_ERROR]
|
||||
Error during import, contact a developer about this issue:
|
||||
{message}
|
@ -50,7 +50,12 @@ class ImportCommand extends SlashCommand {
|
||||
version
|
||||
});
|
||||
await migrator.connect();
|
||||
const imported = await migrator.migrate();
|
||||
let imported = null;
|
||||
try {
|
||||
imported = await migrator.migrate();
|
||||
} catch (err) {
|
||||
return { index: 'COMMAND_IMPORT_ERROR', params: { message: err.message }, emoji: 'failure' };
|
||||
}
|
||||
console.log(imported);
|
||||
console.log(settings);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user