diff --git a/src/utils/Utils.js b/src/utils/Utils.js index 9d648ca..a4f9f9c 100644 --- a/src/utils/Utils.js +++ b/src/utils/Utils.js @@ -62,6 +62,11 @@ export const isAdminLoggedIn = () =>{ if (localStorage.getItem('userData') != null){ return JSON.parse(localStorage.getItem('userData')).role === 'admin' } +} +export const isPrimaryLoggedIn = () =>{ + if (localStorage.getItem('userData') != null){ + return JSON.parse(localStorage.getItem('userData')).role === 'primary' + } } /** ** This function is used for demo purpose route navigation