Browse Source

Add better error message.

pull/114/head
chrislusf 10 years ago
parent
commit
23012deccf
  1. 2
      go/operation/assign_file_id.go

2
go/operation/assign_file_id.go

@ -39,7 +39,7 @@ func Assign(server string, count int, replication string, collection string, ttl
var ret AssignResult var ret AssignResult
err = json.Unmarshal(jsonBlob, &ret) err = json.Unmarshal(jsonBlob, &ret)
if err != nil { if err != nil {
return nil, fmt.Errorf("JSON unmarshal error:%v, json:%s", err, string(jsonBlob))
return nil, fmt.Errorf("/dir/assign result JSON unmarshal error:%v, json:%s", err, string(jsonBlob))
} }
if ret.Count <= 0 { if ret.Count <= 0 {
return nil, errors.New(ret.Error) return nil, errors.New(ret.Error)

Loading…
Cancel
Save