From 8fa6d0d302f487552800ca0d8d60da19b8f99387 Mon Sep 17 00:00:00 2001 From: Unknwon Date: Fri, 10 Mar 2017 16:58:41 -0500 Subject: repo/pull: handle head repository of merged pull requests deleted --- templates/repo/commits_table.tmpl | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'templates/repo/commits_table.tmpl') diff --git a/templates/repo/commits_table.tmpl b/templates/repo/commits_table.tmpl index 1b26572b..a95cb824 100644 --- a/templates/repo/commits_table.tmpl +++ b/templates/repo/commits_table.tmpl @@ -41,7 +41,12 @@ - {{ShortSha .ID.String}} + {{/* Username or Reponame doesn't present we assume the source repository no longer exists */}} + {{if not (and $.Username $.Reponame)}} + {{ShortSha .ID.String}} + {{else}} + {{ShortSha .ID.String}} + {{end}} {{RenderCommitMessage false .Summary $.RepoLink $.Repository.ComposeMetas}} {{TimeSince .Author.When $.Lang}} -- cgit v1.2.3