diff options
| author | Hamidreza Ghavami <70919649+hamid-gh98@users.noreply.github.com> | 2023-05-21 01:59:27 +0300 |
|---|---|---|
| committer | Hamidreza Ghavami <70919649+hamid-gh98@users.noreply.github.com> | 2023-05-21 01:59:27 +0300 |
| commit | d9b1b200cebb82087037d505f13151dd425577a6 (patch) | |
| tree | d9c631ac7491d7216300455fcae9867a6395dae4 /web/controller/util.go | |
| parent | 786a3ac992043e1e1ca398d4b408e34d9ae46973 (diff) | |
rename I18n to I18nWeb
Diffstat (limited to 'web/controller/util.go')
| -rw-r--r-- | web/controller/util.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/web/controller/util.go b/web/controller/util.go index 3d44c11d..da77189b 100644 --- a/web/controller/util.go +++ b/web/controller/util.go @@ -38,12 +38,12 @@ func jsonMsgObj(c *gin.Context, msg string, obj interface{}, err error) { if err == nil { m.Success = true if msg != "" { - m.Msg = msg + WebI18n(c, "success") + m.Msg = msg + I18nWeb(c, "success") } } else { m.Success = false - m.Msg = msg + WebI18n(c, "fail") + ": " + err.Error() - logger.Warning(msg+WebI18n(c, "fail")+": ", err) + m.Msg = msg + I18nWeb(c, "fail") + ": " + err.Error() + logger.Warning(msg+I18nWeb(c, "fail")+": ", err) } c.JSON(http.StatusOK, m) } |
