mirror of
https://github.com/featurebasedb/featurebase.git
synced 2026-09-06 00:25:55 +00:00
support slices of map[string]interface{} in Prettify
This commit is contained in:
parent
7a9544f506
commit
0eda9d2e01
1 changed files with 5 additions and 0 deletions
|
|
@ -27,6 +27,11 @@ func Prettify(m map[string]interface{}) map[string]interface{} {
|
|||
case time.Duration:
|
||||
newmap[k] = PrettyDuration(v.(time.Duration))
|
||||
default:
|
||||
if interv, ok := v.([]map[string]interface{}); ok {
|
||||
for i, iv := range interv {
|
||||
interv[i] = Prettify(iv)
|
||||
}
|
||||
}
|
||||
newmap[k] = v
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue