Skip to content

Commit 047dced

Browse files
authored
Fixed Incidents "Execute command" tab is causing a console error when looking for status property (#522)
1 parent 73bc5d2 commit 047dced

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

frontend/src/app/shared/components/utm/util/utm-agent-connect/utm-agent-connect.component.html

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,19 +18,19 @@
1818
rows="3"></textarea>
1919
</div>
2020

21-
<div *ngIf="agent.status === 'ONLINE'" class="d-flex justify-content-end">
21+
<div *ngIf="agent && agent.status === 'ONLINE'" class="d-flex justify-content-end">
2222
<button class="btn utm-button utm-button-primary" (click)="connectToAgent = true"
2323
[disabled]="!websocketCommand.reason && websocketCommand.reason === ''">
2424
<i class="icon-terminal mr-1"></i>
2525
Connect to console
2626
</button>
2727
</div>
2828
</div>
29-
<div *ngIf="agent.status === 'ONLINE'" class="alert alert-warning alert-styled-right mt-3 alert-dismissible">
29+
<div *ngIf="agent && agent.status === 'ONLINE'" class="alert alert-warning alert-styled-right mt-3 alert-dismissible">
3030
<span class="font-weight-semibold">Warning! </span>
3131
<span>You can cause damage to the infrastructure and services of your organization</span>
3232
</div>
33-
<div *ngIf="agent.status === 'OFFLINE'" class="alert alert-info alert-styled-right mt-3 info-dismissible">
33+
<div *ngIf="agent && agent.status === 'OFFLINE'" class="alert alert-info alert-styled-right mt-3 info-dismissible">
3434
<span class="font-weight-semibold">Info! </span>
3535
<span>Offline agent, data based on the last sync.</span>
3636
</div>

0 commit comments

Comments
 (0)