Fix dashboard commit status null access (#30771)

Fix #30768
pull/27747/head^2
wxiaoguang 7 months ago committed by GitHub
parent 610802df85
commit 5f05e7b41a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
  1. 4
      web_src/js/components/DashboardRepoList.vue

@ -251,9 +251,9 @@ const sfc = {
this.repos = json.data.map((webSearchRepo) => {
return {
...webSearchRepo.repository,
latest_commit_status_state: webSearchRepo.latest_commit_status.State,
latest_commit_status_state: webSearchRepo.latest_commit_status?.State, // if latest_commit_status is null, it means there is no commit status
latest_commit_status_state_link: webSearchRepo.latest_commit_status?.TargetURL,
locale_latest_commit_status_state: webSearchRepo.locale_latest_commit_status,
latest_commit_status_state_link: webSearchRepo.latest_commit_status.TargetURL,
};
});
const count = response.headers.get('X-Total-Count');

Loading…
Cancel
Save