diff options
author | wxiaoguang <wxiaoguang@gmail.com> | 2024-06-13 09:06:46 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-06-13 01:06:46 +0000 |
commit | 47ca61d8ba41f363745f6d0f93cb8efafa92564b (patch) | |
tree | 53d5325e00d626144fa119c7b8a48b498bf347a3 /templates/repo/blame.tmpl | |
parent | 7115dce773e3021b3538ae360c4e7344d5bbf45b (diff) | |
download | gitea-47ca61d8ba41f363745f6d0f93cb8efafa92564b.tar.gz gitea-47ca61d8ba41f363745f6d0f93cb8efafa92564b.zip |
Improve detecting empty files (#31332)
Co-authored-by: silverwind <me@silverwind.io>
Diffstat (limited to 'templates/repo/blame.tmpl')
-rw-r--r-- | templates/repo/blame.tmpl | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/templates/repo/blame.tmpl b/templates/repo/blame.tmpl index 4ad3ed85c9..3e7cd92066 100644 --- a/templates/repo/blame.tmpl +++ b/templates/repo/blame.tmpl @@ -32,6 +32,8 @@ <div class="file-view code-view unicode-escaped"> {{if .IsFileTooLarge}} {{template "shared/filetoolarge" dict "RawFileLink" .RawFileLink}} + {{else if not .FileSize}} + {{template "shared/fileisempty"}} {{else}} <table> <tbody> |