Fix for build.js (#6437)

- Catch potential empty build_detail attribute
This commit is contained in:
Oliver 2024-02-07 10:30:08 +11:00 committed by GitHub
parent 045af50f99
commit df5a3013e6
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -971,7 +971,7 @@ function loadBuildOrderAllocationTable(table, options={}) {
switchable: false,
title: '{% trans "Build Order" %}',
formatter: function(value, row) {
let ref = `${row.build_detail.reference}`;
let ref = row.build_detail?.reference ?? row.build;
let html = renderLink(ref, `/build/${row.build}/`);
html += `- <small>${row.build_detail.title}</small>`;