alerts: use shorthand return

This commit is contained in:
David Lechner
2022-11-22 15:56:56 -06:00
committed by David Lechner
parent 95199e44c1
commit 9fe62467d5
17 changed files with 109 additions and 140 deletions
+6 -8
View File
@@ -11,11 +11,9 @@ const UpdateServerFailure: React.VoidFunctionComponent = () => {
return <p>{i18n.translate('updateServerFailure.message')}</p>;
};
export const updateServerFailure: CreateToast = (onAction) => {
return {
message: <UpdateServerFailure />,
icon: 'error',
intent: Intent.DANGER,
onDismiss: () => onAction('dismiss'),
};
};
export const updateServerFailure: CreateToast = (onAction) => ({
message: <UpdateServerFailure />,
icon: 'error',
intent: Intent.DANGER,
onDismiss: () => onAction('dismiss'),
});