Skip to content

Commit ef4a82a

Browse files
committed
fix
1 parent 2683adf commit ef4a82a

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

routers/api/packages/swift/swift.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -304,7 +304,7 @@ func formFileOptionalReadCloser(ctx *context.Context, formKey string) (io.ReadCl
304304
if content == "" {
305305
return nil, nil
306306
}
307-
return io.NopCloser(strings.NewReader(ctx.Req.FormValue(formKey))), nil
307+
return io.NopCloser(strings.NewReader(content)), nil
308308
}
309309

310310
// UploadPackageFile refers to https://github.com/swiftlang/swift-package-manager/blob/main/Documentation/PackageRegistry/Registry.md#endpoint-6

routers/web/repo/pull.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -196,13 +196,13 @@ func GetPullDiffStats(ctx *context.Context) {
196196

197197
headCommitID, err := ctx.Repo.GitRepo.GetRefCommitID(pull.GetGitRefName())
198198
if err != nil {
199-
ctx.ServerError("GetRefCommitID", err)
199+
log.Error("Failed to GetRefCommitID: %v, repo: %v", err, ctx.Repo.Repository.FullName())
200200
return
201201
}
202202

203203
diffShortStat, err := gitdiff.GetDiffShortStat(ctx.Repo.GitRepo, mergeBaseCommitID, headCommitID)
204204
if err != nil {
205-
ctx.ServerError("GetDiffShortStat", err)
205+
log.Error("Failed to GetDiffShortStat: %v, repo: %v", err, ctx.Repo.Repository.FullName())
206206
return
207207
}
208208

templates/repo/tag/name.tmpl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
<a class="ui label basic tiny button{{if .IsRelease}} primary{{end}}" href="{{.RepoLink}}/src/tag/{{.TagName|PathEscape}}">
1+
<a class="ui basic small label tw-p-1 {{if .IsRelease}}primary{{end}}" href="{{.RepoLink}}/src/tag/{{.TagName|PathEscape}}">
22
{{svg "octicon-tag"}} {{.TagName}}
33
</a>

0 commit comments

Comments
 (0)