We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 49dadde commit ac206e8Copy full SHA for ac206e8
eapi.go
@@ -251,6 +251,7 @@ func (handle *EapiReqHandle) Call() error {
251
commands := handle.getAllCommands()
252
253
jsonrsp, err := handle.node.conn.Execute(commands, handle.encoding)
254
+
255
if err != nil {
256
return err
257
}
@@ -315,7 +316,13 @@ func (handle *EapiReqHandle) parseResponse(resp *JSONRPCResponse) error {
315
316
if cmd.EapiCommand == nil {
317
continue
318
- err := mapstructure.Decode(result, cmd.EapiCommand)
319
320
+ d, err := mapstructure.NewDecoder(&mapstructure.DecoderConfig{ TagName: "json", Result: cmd.EapiCommand })
321
+ if err != nil {
322
+ return err
323
+ }
324
325
+ err = d.Decode(result)
326
327
328
0 commit comments