|
|
|
@ -28,8 +28,12 @@ func (de DecortClient) Check() (*CheckInfo, error) {
|
|
|
|
|
|
|
|
|
|
|
|
err = json.Unmarshal([]byte(strings.Replace(strings.Trim(string(res), `"`), "\\", "", -1)), &info)
|
|
|
|
err = json.Unmarshal([]byte(strings.Replace(strings.Trim(string(res), `"`), "\\", "", -1)), &info)
|
|
|
|
if err != nil {
|
|
|
|
if err != nil {
|
|
|
|
|
|
|
|
if _, exists := constants.VersionMap[string(res)]; exists {
|
|
|
|
|
|
|
|
info.Version = string(res)
|
|
|
|
|
|
|
|
} else {
|
|
|
|
return nil, err
|
|
|
|
return nil, err
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
if v, ok := constants.VersionMap[info.Version]; ok {
|
|
|
|
if v, ok := constants.VersionMap[info.Version]; ok {
|
|
|
|
if v == "-" {
|
|
|
|
if v == "-" {
|
|
|
|
|