mirror of
https://github.com/go-gitea/gitea.git
synced 2026-08-08 12:27:44 +00:00
d4333eb043
### Issue Fully publishing a draft release fails when the release does not have a target set. A draft release can be created without a target because the Git tag is not created while the release remains a draft. However, when the draft is published, Gitea attempts to resolve the release target to create the tag. If the target is empty, the publish operation fails. ### Solution Use the repository's default branch as the target when a draft release is published without an explicitly configured target. Also add a regression test to verify that a draft release without a target can be successfully published. Fixes #35569 --------- Signed-off-by: wxiaoguang <wxiaoguang@gmail.com> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>