userpage: show and allow modification of contact methods
This commit is contained in:
+9
-4
@@ -144,6 +144,10 @@ func (st *Storage) loadLang(filesystems ...fs.FS) (err error) {
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
err = st.loadLangEmail(filesystems...)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
err = st.loadLangUser(filesystems...)
|
||||
if err != nil {
|
||||
return
|
||||
@@ -152,10 +156,6 @@ func (st *Storage) loadLang(filesystems ...fs.FS) (err error) {
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
err = st.loadLangEmail(filesystems...)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
err = st.loadLangTelegram(filesystems...)
|
||||
return
|
||||
}
|
||||
@@ -437,6 +437,11 @@ func (st *Storage) loadLangUser(filesystems ...fs.FS) error {
|
||||
}
|
||||
st.lang.Common.patchCommonStrings(&lang.Strings, index)
|
||||
st.lang.Common.patchCommonNotifications(&lang.Notifications, index)
|
||||
// turns out, a lot of email strings are useful on the user page.
|
||||
emailLang := []langSection{st.lang.Email[index].WelcomeEmail, st.lang.Email[index].UserDisabled, st.lang.Email[index].UserExpired}
|
||||
for _, v := range emailLang {
|
||||
patchLang(&lang.Strings, &v)
|
||||
}
|
||||
if fname != "en-us.json" {
|
||||
if lang.Meta.Fallback != "" {
|
||||
fallback, ok := st.lang.User[lang.Meta.Fallback]
|
||||
|
||||
Reference in New Issue
Block a user