Skip to content

Commit d3f797b

Browse files
committed
fix view-allocations permissions check in templates, closes pterodactyl#1021
1 parent c9e874d commit d3f797b

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ This project follows [Semantic Versioning](http://semver.org) guidelines.
66
## v0.7.6 (Derelict Dermodactylus)
77
### Fixed
88
* Fixes a UI error when attempting to change the default Nest and Egg for an existing server.
9+
* Correct permissions check in UI to allow subusers with permission to `view-allocations` the ability to actually see the sidebar link.
910

1011
## v0.7.5 (Derelict Dermodactylus)
1112
### Fixed

resources/themes/pterodactyl/layouts/master.blade.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,7 @@ class="active"
170170
</a>
171171
</li>
172172
@endcan
173-
@if(Gate::allows('view-startup', $server) || Gate::allows('access-sftp', $server) || Gate::allows('view-allocation', $server))
173+
@if(Gate::allows('view-startup', $server) || Gate::allows('access-sftp', $server) || Gate::allows('view-allocations', $server))
174174
<li class="treeview
175175
@if(starts_with(Route::currentRouteName(), 'server.settings'))
176176
active
@@ -184,7 +184,7 @@ class="active"
184184
</span>
185185
</a>
186186
<ul class="treeview-menu">
187-
@can('view-allocation', $server)
187+
@can('view-allocations', $server)
188188
<li class="{{ Route::currentRouteName() !== 'server.settings.allocation' ?: 'active' }}"><a href="{{ route('server.settings.allocation', $server->uuidShort) }}"><i class="fa fa-angle-right"></i> @lang('navigation.server.port_allocations')</a></li>
189189
@endcan
190190
@can('access-sftp', $server)

0 commit comments

Comments
 (0)