213
This commit is contained in:
parent
1f49dc7987
commit
6ef44cb294
|
@ -4,6 +4,7 @@ import (
|
||||||
"encoding/json"
|
"encoding/json"
|
||||||
"log"
|
"log"
|
||||||
"regexp"
|
"regexp"
|
||||||
|
"strconv"
|
||||||
"strings"
|
"strings"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
|
@ -43,6 +44,8 @@ func (tt *Toutiao) ToDoParser(adstring string) (string, error) {
|
||||||
|
|
||||||
for _, data := range adlist {
|
for _, data := range adlist {
|
||||||
data = strings.Trim(data, "\"")
|
data = strings.Trim(data, "\"")
|
||||||
|
unq, _ := strconv.Unquote("\"" + data + "\"")
|
||||||
|
data = unq
|
||||||
var v interface{}
|
var v interface{}
|
||||||
json.Unmarshal([]byte(data), &v)
|
json.Unmarshal([]byte(data), &v)
|
||||||
spew.Dump(v)
|
spew.Dump(v)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user