Skip to content

Commit 0ca2332

Browse files
GiteaBotmemphis88
andauthored
Fix organization field being null in POST /orgs/{orgid}/teams (#27150) (#27163)
Backport #27150 by @memphis88 Similarly to the fix in #24694, this addresses the team creation not returning the organization information in the response. This fix is connected to the [issue](https://gitea.com/gitea/terraform-provider-gitea/issues/27) discovered in the terraform provider. Moreover, the [documentation](https://docs.gitea.com/api/1.20/#tag/organization/operation/orgCreateTeam) suggests that the response body should include the `organization` field (currently being `null`). Co-authored-by: Dionysios Kakouris <[email protected]>
1 parent c3b7120 commit 0ca2332

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

routers/api/v1/org/team.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -248,7 +248,7 @@ func CreateTeam(ctx *context.APIContext) {
248248
return
249249
}
250250

251-
apiTeam, err := convert.ToTeam(ctx, team)
251+
apiTeam, err := convert.ToTeam(ctx, team, true)
252252
if err != nil {
253253
ctx.InternalServerError(err)
254254
return

0 commit comments

Comments
 (0)