1
1
mirror of https://github.com/go-gitea/gitea synced 2024-12-24 01:24:26 +00:00

Fix GetContents(): Dont't ignore Executables (#11192) (#11209)

This commit is contained in:
6543 2020-04-25 06:54:38 +02:00 committed by GitHub
parent 4a6765fba2
commit bfc25fcf40
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -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