mirror of
https://github.com/ZeppelinBot/Zeppelin.git
synced 2025-05-12 04:55:01 +00:00
resolveUser: return null if the passed value is not a valid id
This commit is contained in:
parent
5215dd0738
commit
a641312853
6 changed files with 21 additions and 4 deletions
|
@ -6,6 +6,7 @@ export enum ERRORS {
|
|||
INVALID_EMOJI,
|
||||
NO_USER_NOTIFICATION_CHANNEL,
|
||||
INVALID_USER_NOTIFICATION_CHANNEL,
|
||||
INVALID_USER,
|
||||
}
|
||||
|
||||
export const RECOVERABLE_PLUGIN_ERROR_MESSAGES = {
|
||||
|
@ -14,6 +15,7 @@ export const RECOVERABLE_PLUGIN_ERROR_MESSAGES = {
|
|||
[ERRORS.INVALID_EMOJI]: "Invalid emoji",
|
||||
[ERRORS.NO_USER_NOTIFICATION_CHANNEL]: "No user notify channel specified",
|
||||
[ERRORS.INVALID_USER_NOTIFICATION_CHANNEL]: "Invalid user notify channel specified",
|
||||
[ERRORS.INVALID_USER]: "Invalid user",
|
||||
};
|
||||
|
||||
export class RecoverablePluginError extends Error {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue