fix issue in concurrent safety for gview.Parse; rename glog.*fln functions to glog.*f

This commit is contained in:
John
2019-06-05 20:22:57 +08:00
parent 6fecf8bb01
commit d1f0fa1a47
16 changed files with 85 additions and 43 deletions

View File

@ -136,7 +136,10 @@ func LoadContent(data interface{}, unsafe...bool) (*Json, error) {
var err error
var result interface{}
b := gconv.Bytes(data)
t := "json"
t := ""
if len(b) == 0 {
return New(nil, unsafe...), nil
}
// auto check data type
if json.Valid(b) {
t = "json"