HOTFIX: Prevent error on tickets without state
gitea/salix/pipeline/head This commit looks good Details

This commit is contained in:
Joan Sanchez 2021-06-22 14:11:33 +02:00
parent 7d93f0ac0e
commit 256203944e
1 changed files with 2 additions and 0 deletions

View File

@ -59,6 +59,8 @@ class Controller extends Summary {
stateColor(ticket) {
const ticketState = ticket.ticketState;
if (!ticketState) return;
if (ticketState.code === 'OK')
return 'success';
else if (ticketState.code === 'FREE')