Skip to content

Commit

Permalink
feat: add isAlexander
Browse files Browse the repository at this point in the history
  • Loading branch information
ialexanderbrito committed Apr 11, 2022
1 parent ed99a58 commit 3f004fb
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/contexts/Auth.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,14 @@ export function AuthProvider({ children }: any) {
return false;
}

function isAlexander() {
if (user?.email === '[email protected]') {
return true;
}

return false;
}

async function checkUser() {
const hash = window.location.href.split('#')[0];
const params = hash.split('/')[3];
Expand Down Expand Up @@ -196,6 +204,7 @@ export function AuthProvider({ children }: any) {
loading,
isBarbeiro: isBarbeiro(),
isCliente: isCliente(),
isAlexander: isAlexander(),
}}
>
{children}
Expand Down

0 comments on commit 3f004fb

Please sign in to comment.