fix YQL bugs:the chat '&' doesn't encoded

This commit is contained in:
darcy
2017-05-17 15:55:40 +08:00
parent 81e7d2bdca
commit e63dfc9291
+1 -1
View File
@@ -50,7 +50,7 @@ const fetch = (options) => {
})
})
} else if (fetchType === 'YQL') {
url = `http://query.yahooapis.com/v1/public/yql?q=select * from json where url='${options.url}?${qs.stringify(options.data)}'&format=json`
url = `http://query.yahooapis.com/v1/public/yql?q=select * from json where url='${options.url}?${encodeURIComponent(qs.stringify(options.data))}'&format=json`
data = null
}