chore: remove #11024 workarounds (#12301)

remove two workarounds which are not required any more

Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/12301
Reviewed-by: Gusted <gusted@noreply.codeberg.org>
This commit is contained in:
Nils Goroll 2026-05-01 22:10:10 +02:00 committed by Gusted
parent d867b25e72
commit 9d323c5125
2 changed files with 6 additions and 11 deletions

View file

@ -77,15 +77,12 @@ func loadLFSFrom(rootCfg ConfigProvider) error {
return nil
}
// TODO: #11024 check nil because settings loaded twice
if LFS.SigningKey == nil {
keyCfg, err := loadKeyCfg(rootCfg, "server", "LFS_JWT_", "HS256", "lfs/private.pem")
if err == nil {
LFS.SigningKey, err = jwtx.InitSigningKey(&keyCfg.Signing)
}
if err != nil {
return fmt.Errorf("lfs key initialization failed: %v", err)
}
keyCfg, err := loadKeyCfg(rootCfg, "server", "LFS_JWT_", "HS256", "lfs/private.pem")
if err == nil {
LFS.SigningKey, err = jwtx.InitSigningKey(&keyCfg.Signing)
}
if err != nil {
return fmt.Errorf("lfs key initialization failed: %v", err)
}
return nil

View file

@ -105,8 +105,6 @@ var cfgVariants = []namedCfg{
}
func TestAuthenticate(t *testing.T) {
// TODO: #11024
setting.InstallLock = true
for _, v := range cfgVariants {
cfg := iniCommon + v.cfg
t.Run(v.name, func(t *testing.T) { testAuthenticate(t, cfg) })