Skip to content

Commit

Permalink
fix(rbac): deleted unused imports
Browse files Browse the repository at this point in the history
  • Loading branch information
imjulianeral committed Sep 2, 2021
1 parent f596a2a commit 576e87b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/components/NextShield.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import React, { ReactNode, useEffect } from 'react'
import React, { ReactNode } from 'react'

import { NextShieldProps } from '../types/props'
import { getAccessRoute, verifyPath } from '../libs/routes'
import { verifyPath } from '../libs/routes'

/**
* 😉 The shield that every Next.js project needs
Expand Down Expand Up @@ -63,7 +63,7 @@ export function NextShield<
const pathIsHybrid = verifyPath(hybridRoutes, pathname)
const pathIsAuthorized =
RBAC && userRole && verifyPath(RBAC[userRole].grantedRoutes, pathname)
const access = getAccessRoute(RBAC, userRole, accessRoute) as string
// const access = getAccessRoute(RBAC, userRole, accessRoute)

// useEffect(() => {
// if (!isAuth && !isLoading && pathIsPrivate) replace(loginRoute)
Expand Down

0 comments on commit 576e87b

Please sign in to comment.