-i устарела

This commit is contained in:
Бородин Роман 2023-07-31 13:24:46 +03:00
parent 35ac5a50d6
commit 593d9241be
2 changed files with 4 additions and 5 deletions

View File

@ -17,7 +17,6 @@ package i18n
import ( import (
"encoding/json" "encoding/json"
"io/ioutil"
"os" "os"
"sort" "sort"
"strings" "strings"
@ -59,7 +58,7 @@ func Load() {
} }
func load(localeStr string) { func load(localeStr string) {
bytes, err := ioutil.ReadFile("i18n/" + localeStr + ".json") bytes, err := os.ReadFile("i18n/" + localeStr + ".json")
if nil != err { if nil != err {
logger.Error(err) logger.Error(err)

View File

@ -124,9 +124,9 @@ func BuildHandler(w http.ResponseWriter, r *http.Request) {
var goBuildArgs []string var goBuildArgs []string
goBuildArgs = append(goBuildArgs, "build") goBuildArgs = append(goBuildArgs, "build")
goBuildArgs = append(goBuildArgs, user.BuildArgs(runtime.GOOS)...) goBuildArgs = append(goBuildArgs, user.BuildArgs(runtime.GOOS)...)
if !gulu.Str.Contains("-i", goBuildArgs) { //if !gulu.Str.Contains("-i", goBuildArgs) {
goBuildArgs = append(goBuildArgs, "-i") // goBuildArgs = append(goBuildArgs, "-i")
} //}
cmd := exec.Command("go", goBuildArgs...) cmd := exec.Command("go", goBuildArgs...)
cmd.Dir = curDir cmd.Dir = curDir