We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 14354e4 commit 1be63d2Copy full SHA for 1be63d2
routers/web/repo/view.go
@@ -713,14 +713,7 @@ func checkCitationFile(ctx *context.Context, entry *git.TreeEntry) {
713
if entry.Name() == "CITATION.cff" || entry.Name() == "CITATION.bib" {
714
ctx.Data["CitiationExist"] = true
715
// Read Citation file contents
716
- blob := entry.Blob()
717
- dataRc, err := blob.DataAsync()
718
- if err != nil {
719
- ctx.ServerError("DataAsync", err)
720
- return
721
- }
722
- defer dataRc.Close()
723
- ctx.PageData["citationFileContent"], err = blob.GetBlobContent(setting.UI.MaxDisplayFileSize)
+ ctx.PageData["citationFileContent"], err = entry.Blob().GetBlobContent(setting.UI.MaxDisplayFileSize)
724
if err != nil {
725
ctx.ServerError("GetBlobContent", err)
726
return
0 commit comments