From 3bdcc663df668d1f2aa2dee15f4298467b250625 Mon Sep 17 00:00:00 2001 From: zhaoke Date: Fri, 28 Jul 2023 15:31:32 +0800 Subject: [PATCH] + Fix js error of repo. --- module/repo/js/browse.ui.js | 3 ++- module/repo/js/log.ui.js | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/module/repo/js/browse.ui.js b/module/repo/js/browse.ui.js index 91918685d7..d0f13cf102 100644 --- a/module/repo/js/browse.ui.js +++ b/module/repo/js/browse.ui.js @@ -115,7 +115,8 @@ window.diffClick = function() window.canRowCheckable = function(rowID) { const dtable = zui.DTable.query('#repo-comments-table'); - var data = dtable.$.props.data; + if(dtable == undefined) return; + var data = dtable.$.props.data; if(data.length == 0) return true; diff --git a/module/repo/js/log.ui.js b/module/repo/js/log.ui.js index 6859b7ff84..7c411cf9b3 100644 --- a/module/repo/js/log.ui.js +++ b/module/repo/js/log.ui.js @@ -34,7 +34,8 @@ window.checkedChange = function(changes) window.canRowCheckable = function(rowID) { const dtable = zui.DTable.query('#repo-logs-table'); - var data = dtable.$.props.data; + if(dtable == undefined) return; + var data = dtable.$.props.data; if(data.length == 0) return true;