summaryrefslogtreecommitdiffstats
path: root/modules
diff options
context:
space:
mode:
authorzeripath <art27@cantab.net>2019-05-21 22:32:52 +0100
committerGitHub <noreply@github.com>2019-05-21 22:32:52 +0100
commit0d69dfb4ca102186e68227dfca9eea1ce09e445b (patch)
tree94fbcb36498dfe0addc4be95d8a62d3f7b7cc55f /modules
parent84bfd005377d0693a4ebd52fa305f57fba6be989 (diff)
downloadgitea-0d69dfb4ca102186e68227dfca9eea1ce09e445b.tar.gz
gitea-0d69dfb4ca102186e68227dfca9eea1ce09e445b.zip
Do not attempt to return blob on submodule (#6996)
Diffstat (limited to 'modules')
-rw-r--r--modules/git/tree_blob.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/git/tree_blob.go b/modules/git/tree_blob.go
index 14237df6e8..eb8ddd0946 100644
--- a/modules/git/tree_blob.go
+++ b/modules/git/tree_blob.go
@@ -60,7 +60,7 @@ func (t *Tree) GetBlobByPath(relpath string) (*Blob, error) {
return nil, err
}
- if !entry.IsDir() {
+ if !entry.IsDir() && !entry.IsSubModule() {
return entry.Blob(), nil
}