From f6b118dd8c90507190c98ba625e6122c9b2ed61c Mon Sep 17 00:00:00 2001 From: Daniel Mulholland Date: Tue, 30 Jan 2024 06:47:06 +1300 Subject: [PATCH] Remove missing control rendering --- oscd-supervision.ts | 22 +++++----------------- 1 file changed, 5 insertions(+), 17 deletions(-) diff --git a/oscd-supervision.ts b/oscd-supervision.ts index 175f7d7..5a0bb33 100644 --- a/oscd-supervision.ts +++ b/oscd-supervision.ts @@ -829,24 +829,12 @@ export default class OscdSupervision extends LitElement { ${this.getSelectedIedSupLNs(true, false).map(lN => { const cbRef = getSupervisionCBRef(lN); - const controlElement = - getOtherIedControlElements(this.selectedIed, this.controlType).find( - control => cbRef === controlBlockReference(control) - ) ?? null; + const controlElement = getOtherIedControlElements( + this.selectedIed, + this.controlType + ).find(control => cbRef === controlBlockReference(control))!; - return html`${controlElement - ? this.renderControl(controlElement) - : html` - Control not found - ${this.controlType === 'GOOSE' ? gooseIcon : smvIcon} - `}`; + return this.renderControl(controlElement); })}`; }