refactor(contacts/contactalert): Cleaned up code

Reduced redundant code and added switch statement
This commit is contained in:
Taso authored and Taso committed 2020-12-13 00:07:38 -05:00
1 parent 96224eb239
commit 65de9d78a3
3 files changed
+44 -31

No files matched your search

+9 -1
View File
@@ -1,4 +1,12 @@
export type AlertCategory =
| 'CONTACT_ADD_SUCCESS'
| 'CONTACT_ADD_FAILED'
| 'CONTACT_UPDATE_SUCCESS'
| 'CONTACT_UPDATE_FAILED'
| 'CONTACT_DELETE_SUCCESS'
| 'CONTACT_DELETE_FAILED';
export interface IContactAlert {
alert: string;
alert: AlertCategory;
setAlert: (type: string) => void;
}