From bfc25fcf40eede98424f1af8287c603f99f8de87 Mon Sep 17 00:00:00 2001
From: 6543 <6543@obermui.de>
Date: Sat, 25 Apr 2020 06:54:38 +0200
Subject: [PATCH] Fix GetContents(): Dont't ignore Executables (#11192)
 (#11209)

---
 modules/repofiles/content.go | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/modules/repofiles/content.go b/modules/repofiles/content.go
index aed98c33a8..838bfabdc6 100644
--- a/modules/repofiles/content.go
+++ b/modules/repofiles/content.go
@@ -159,7 +159,7 @@ func GetContents(repo *models.Repository, treePath, ref string, forList bool) (*
 	}
 
 	// Now populate the rest of the ContentsResponse based on entry type
-	if entry.IsRegular() {
+	if entry.IsRegular() || entry.IsExecutable() {
 		contentsResponse.Type = string(ContentTypeRegular)
 		if blobResponse, err := GetBlobBySHA(repo, entry.ID.String()); err != nil {
 			return nil, err