gitea/services
Kemal Zebari ecd463c2f1
Validate that the tag doesn't exist when creating a tag via the web (#33241)
Found while investigating #33210.

This line no longer makes sense because the form field "TagName" is
required, so this would mean that this code path would never be covered.
Because it isn't covered, we end up going down the "update release"
logic where we eventually set `Release.IsTag` to false (meaning it will
now be treated as a release instead of a tag).

This snapshot rewrites the condition to ensure that we aren't trying to
create a tag that already exists.

---------

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
2025-01-14 09:27:35 +08:00
..
actions Refactor RefName (#33234) 2025-01-13 14:01:53 +08:00
agit
asymkey
attachment
auth
automerge
context Fix incorrect ref "blob" (#33240) 2025-01-13 16:27:11 +08:00
contexttest
convert
cron
doctor
externalaccount
feed Refactor RefName (#33234) 2025-01-13 14:01:53 +08:00
forms Validate that the tag doesn't exist when creating a tag via the web (#33241) 2025-01-14 09:27:35 +08:00
gitdiff
indexer
issue Refactor RefName (#33234) 2025-01-13 14:01:53 +08:00
lfs
mailer
markup
migrations
mirror Fix mirror bug (#33224) 2025-01-12 18:46:37 +08:00
notify
oauth2_provider
org
packages
projects
pull
release
repository Refactor context RefName and RepoAssignment (#33226) 2025-01-13 01:07:05 +00:00
secrets
task
uinotification
user
webhook Refactor RefName (#33234) 2025-01-13 14:01:53 +08:00
webtheme
wiki