Skip to content

Commit

Permalink
Add shutting down notice (go-gitea#25920) (go-gitea#25922)
Browse files Browse the repository at this point in the history
Backport go-gitea#25920 by @KN4CK3R

Got the same problem as go-gitea#25915 when updating an instance. The
`log.Fatal` should have been marked as breaking in go-gitea#23911.

This PR adds a notice that the system is shutting down because of the
deprecated setting.

Co-authored-by: KN4CK3R <[email protected]>
  • Loading branch information
GiteaBot and KN4CK3R committed Jul 17, 2023
1 parent 36b9a86 commit 6e82d0b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion modules/setting/config_provider.go
Original file line number Diff line number Diff line change
Expand Up @@ -324,7 +324,7 @@ func deprecatedSetting(rootCfg ConfigProvider, oldSection, oldKey, newSection, n

func deprecatedSettingFatal(rootCfg ConfigProvider, oldSection, oldKey, newSection, newKey, version string) {
if rootCfg.Section(oldSection).HasKey(oldKey) {
log.Fatal("Deprecated fallback `[%s]` `%s` present. Use `[%s]` `%s` instead. This fallback will be/has been removed in %s", oldSection, oldKey, newSection, newKey, version)
log.Fatal("Deprecated fallback `[%s]` `%s` present. Use `[%s]` `%s` instead. This fallback will be/has been removed in %s. Shutting down", oldSection, oldKey, newSection, newKey, version)
}
}

Expand Down

0 comments on commit 6e82d0b

Please sign in to comment.