Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
function decoder(json) {
return Json_decode.map(fromRecord, (function (json) {
return /* record */[
/* type_ */Json_decode.field("type", Json_decode.string, json),
/* rank */Json_decode.field("rank", Json_decode.$$int, json)
];
}), json);
}
var test = Json_decode.either((function (param) {
return Json_decode.map((function (param) {
return /* record */[
/* id */param[0],
/* language */param[1],
/* code */param[2]
];
}), (function (param) {
return Json_decode.tuple3(id, language, Json_decode.string, param);
}), param);
}), (function (param) {
return Json_decode.map((function (param) {
function decoder(json) {
return Json_decode.map(fromStatList, StatList$Mxdbmobile.decoder, json);
}