Fakultas Ilmu Komputer UI

Commit 18b838c7 authored by FadhilP's avatar FadhilP
Browse files

export isAdmin function to auth.service

parent 49626b4e
......@@ -24,3 +24,6 @@ export const authHeader = () => {
};
export const loggedIn = JSON.parse(localStorage.getItem('user')) && 1;
export const isAdmin =
loggedIn && JSON.parse(localStorage.getItem('user'))?.data?.role;
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment