Commit 2290d4e2 by chenweitao

Merge branch 'working' into 'master'

Working

See merge request !160
parents 52ac9991 2e1ca3af
......@@ -455,7 +455,7 @@ public class WeiboHotSearchCrawler {
weiBoMassageDao.addWeiBoMassage(weiBoMassage);
}
}
} else if (jsonObject.containsKey("card_group")) {
} else if (jsonObject.containsKey("card_group")&& nonNull(jsonObject.getJSONArray("card_group"))) {
JSONArray cardGroup = jsonObject.getJSONArray("card_group");
WeiBoMassage weiBoMassage = analysisWeiboMassage(cardGroup, document.getString("name"));
if (Objects.nonNull(weiBoMassage)) {
......@@ -625,7 +625,8 @@ public class WeiboHotSearchCrawler {
//解析weibo人物信息
Date date = new Date();
for (int i = 0; i < cardGroup.size(); i++) {
if (3 == Integer.valueOf(cardGroup.getJSONObject(i).getString("card_type"))) {
Integer cardType = Integer.valueOf(cardGroup.getJSONObject(i).getString("card_type"));
if (24 == cardType||3 == cardType) {
if (cardGroup.getJSONObject(i).containsKey("users")) {
JSONArray users = cardGroup.getJSONObject(i).getJSONArray("users");
for (int i1 = 0; i1 < users.size(); i1++) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment