From 021c4394871e062964e1601775f4c951d0e2b878 Mon Sep 17 00:00:00 2001 From: Miguel Angel Mulero Martinez Date: Thu, 19 Oct 2023 11:49:57 +0200 Subject: luci-app-attendedsysupgrade: fix search for x86 target The conditional is wrong. IndexOf returns a number and not true/false, so it does not work. Signed-off-by: Miguel Angel Mulero Martinez --- .../htdocs/luci-static/resources/view/attendedsysupgrade/overview.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'applications/luci-app-attendedsysupgrade/htdocs/luci-static') diff --git a/applications/luci-app-attendedsysupgrade/htdocs/luci-static/resources/view/attendedsysupgrade/overview.js b/applications/luci-app-attendedsysupgrade/htdocs/luci-static/resources/view/attendedsysupgrade/overview.js index 7b067d7e8d..450af35496 100644 --- a/applications/luci-app-attendedsysupgrade/htdocs/luci-static/resources/view/attendedsysupgrade/overview.js +++ b/applications/luci-app-attendedsysupgrade/htdocs/luci-static/resources/view/attendedsysupgrade/overview.js @@ -89,7 +89,7 @@ return view.extend({ for (image of images) { if (this.firmware.filesystem == image.filesystem) { // x86 images can be combined-efi (EFI) or combined (BIOS) - if(this.firmware.target.indexOf("x86")) { + if(this.firmware.target.indexOf("x86") != -1) { if (this.data.efi && image.type == 'combined-efi') { return image; } else if (image.type == 'combined') { -- cgit v1.2.3