File tree Expand file tree Collapse file tree 1 file changed +6
-0
lines changed
Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -13,6 +13,8 @@ import (
1313 "path/filepath"
1414 "strings"
1515 "time"
16+
17+ "code.gitea.io/gitea/modules/log"
1618)
1719
1820var (
@@ -83,6 +85,10 @@ func InitDBConfig() {
8385 Database .Schema = sec .Key ("SCHEMA" ).String ()
8486 Database .SSLMode = sec .Key ("SSL_MODE" ).MustString ("disable" )
8587 Database .Charset = sec .Key ("CHARSET" ).In (defaultCharset , []string {"utf8" , "utf8mb4" })
88+ if Database .UseMySQL && defaultCharset != "utf8mb4" {
89+ log .Error ("Deprecated database mysql charset utf8 support, please use utf8mb4 or convert utf8 to utf8mb4." )
90+ }
91+
8692 Database .Path = sec .Key ("PATH" ).MustString (filepath .Join (AppDataPath , "gitea.db" ))
8793 Database .Timeout = sec .Key ("SQLITE_TIMEOUT" ).MustInt (500 )
8894 Database .MaxIdleConns = sec .Key ("MAX_IDLE_CONNS" ).MustInt (2 )
You can’t perform that action at this time.
0 commit comments