Skip to content
Snippets Groups Projects
Commit c176e695 authored by Fabian Bläse's avatar Fabian Bläse
Browse files

rudi comments

parent acc82f15
No related branches found
No related tags found
No related merge requests found
......@@ -103,6 +103,11 @@ func subdissect(data map[string]interface{}) interface{} {
}
if dissector == "" {
// github.com/pkg/errors
// return nil, errors.Wrapf(err, "...")
// (foo, error)
// return nil, fmt.Errorf("no dissector given or found for subdissect request")
// log.Printf("no dissector given or found for subdissect request")
fmt.Fprintln(os.Stderr, "No dissector given or found for subdissect request.")
return nil
}
......@@ -160,6 +165,13 @@ func dissect(data []byte, dissector string) interface{} {
err = json.Unmarshal(out.Bytes(), &decode);
die(err)
/*
type foo struct {
Subdisect string `json:'_subdisect'`
}
[]map[string]foo
*/
check_for_subdissect(&decode)
return decode
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment