diff --git a/webapp/src/views/SystemInfoView.vue b/webapp/src/views/SystemInfoView.vue index 3e667d165..6c3e843c5 100644 --- a/webapp/src/views/SystemInfoView.vue +++ b/webapp/src/views/SystemInfoView.vue @@ -58,12 +58,16 @@ export default defineComponent({ }) }, getUpdateInfo() { + if (this.systemDataList.git_hash === undefined) { + return; + } + // If the left char is a "g" the value is the git hash (remove the "g") this.systemDataList.git_is_hash = this.systemDataList.git_hash?.substring(0, 1) == 'g'; this.systemDataList.git_hash = this.systemDataList.git_is_hash ? this.systemDataList.git_hash?.substring(1) : this.systemDataList.git_hash; // Handle format "v0.1-5-gabcdefh" - if (this.systemDataList.git_hash.lastIndexOf("-") >= 0) { + if (this.systemDataList.git_hash?.lastIndexOf("-") >= 0) { this.systemDataList.git_hash = this.systemDataList.git_hash.substring(this.systemDataList.git_hash.lastIndexOf("-") + 2) this.systemDataList.git_is_hash = true; }