Seems like you need to cast the stdClass Objects as Array so you can have the structure you are looking for
$result = array_map(function ($value) {
return (array)$value;
}, $result);
Seems like you need to cast the stdClass Objects as Array so you can have the structure you are looking for
$result = array_map(function ($value) {
return (array)$value;
}, $result);