mirror of
https://github.com/johnkerl/miller.git
synced 2026-08-02 12:32:21 +00:00
json-number fixup
This commit is contained in:
parent
1f7f0ef723
commit
3a166ea667
1 changed files with 2 additions and 3 deletions
|
|
@ -6,7 +6,6 @@ import (
|
|||
//"fmt"
|
||||
"os"
|
||||
//"reflect"
|
||||
"strconv"
|
||||
|
||||
// Miller:
|
||||
"miller/containers"
|
||||
|
|
@ -84,9 +83,9 @@ func (this *RecordReaderJSON) Read(
|
|||
if ok {
|
||||
lrec.Put(&key, &sval)
|
||||
} else {
|
||||
nval, ok := value.(float64)
|
||||
nval, ok := value.(json.Number)
|
||||
if ok {
|
||||
sval = strconv.FormatFloat(nval, 'g', -1, 64)
|
||||
sval = nval.String()
|
||||
lrec.Put(&key, &sval)
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue