1 | <?php |
||
2 | use Laravel\Nova\Nova; |
||
0 ignored issues
–
show
|
|||
3 | use Spatie\Permission\PermissionRegistrar; |
||
4 | ?> |
||
5 | |||
6 | @if ((Nova::resourceForModel(app(PermissionRegistrar::class)->getRoleClass()))::authorizedToViewAny(request()) || (Nova::resourceForModel(app(PermissionRegistrar::class)->getPermissionClass()))::authorizedToViewAny(request())) |
||
7 | <h3 class="flex items-center font-normal text-white mb-6 text-base no-underline"> |
||
8 | <svg class="sidebar-icon" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"> |
||
9 | <path fill="var(--sidebar-icon)" |
||
10 | d="M7 10V7a5 5 0 1 1 10 0v3h2a2 2 0 0 1 2 2v8a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-8c0-1.1.9-2 2-2h2zm2 0h6V7a3 3 0 0 0-6 0v3zm-4 2v8h14v-8H5zm7 2a1 1 0 0 1 1 1v2a1 1 0 0 1-2 0v-2a1 1 0 0 1 1-1z"/> |
||
11 | </svg> |
||
12 | <span class="sidebar-label"> |
||
13 | @lang('laravel-nova-permission::navigation.sidebar-label') |
||
14 | </span> |
||
15 | </h3> |
||
16 | |||
17 | <ul class="list-reset mb-8"> |
||
18 | |||
19 | @if((Nova::resourceForModel(app(PermissionRegistrar::class)->getRoleClass()))::authorizedToViewAny(request())) |
||
20 | <li class="leading-wide mb-4 text-sm"> |
||
21 | <router-link :to="{ |
||
22 | name: 'index', |
||
23 | params: { |
||
24 | resourceName: 'roles' |
||
25 | } |
||
26 | }" class="text-white ml-8 no-underline dim"> |
||
27 | @lang('laravel-nova-permission::resources.Roles') |
||
28 | </router-link> |
||
29 | </li> |
||
30 | @endif |
||
31 | |||
32 | @if((Nova::resourceForModel(app(PermissionRegistrar::class)->getPermissionClass()))::authorizedToViewAny(request())) |
||
33 | <li class="leading-wide mb-4 text-sm"> |
||
34 | <router-link :to="{ |
||
35 | name: 'index', |
||
36 | params: { |
||
37 | resourceName: 'permissions' |
||
38 | } |
||
39 | }" class="text-white ml-8 no-underline dim"> |
||
40 | @lang('laravel-nova-permission::resources.Permissions') |
||
41 | </router-link> |
||
42 | </li> |
||
43 | @endif |
||
44 | |||
45 | </ul> |
||
46 | @endif |
The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g.
excluded_paths: ["lib/*"]
, you can move it to the dependency path list as follows:For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths