Skip to content

Commit

Permalink
Fix test for whether ptz button is disabled
Browse files Browse the repository at this point in the history
  • Loading branch information
Isaac Connor committed Jul 5, 2024
1 parent c369826 commit 474abe6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion web/skins/classic/views/watch.php
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ function getStreamModeMonitor($monitor) {
</button>
<button type="button" id="ptzToggle" class="btn <?php echo $showPtzControls ? 'btn-primary':'btn-secondary'?>"
<?php
if ($hasPtzControls) {
if ($monitor->Controllable() && canView('Control') && ($monitor->Type() != 'WebSite')) {
echo 'title="'.translate('Toggle PTZ Controls').'"';
} else {
echo 'disabled="disabled" title="'.translate('PTZ Not available').'"';
Expand Down

0 comments on commit 474abe6

Please sign in to comment.