Commit 6ce658e0 by zhiwei

修改来源验证问题

parent 90fc68cf
......@@ -33,14 +33,14 @@ public class SourceForwardPageProcessor implements PageProcessor {
String source = null;
String channel = "新闻";
try {
channel = verifyChannel(page.getUrl().get());
if(channel==null){
if(page.getStatusCode()!=404){
List<Node> nodeList = page.getHtml().getDocument().head().childNodes();
source = TreateData.matchSource(page.getUrl().get(),page.getHtml().toString(), sourceList);
channel = TreateData.matchChannel(nodeList);
if(page.getStatusCode()!=404){
channel = verifyChannel(page.getUrl().get());
if(channel==null){
List<Node> nodeList = page.getHtml().getDocument().head().childNodes();
channel = TreateData.matchChannel(nodeList);
}
source = TreateData.matchSource(page.getUrl().get(),page.getHtml().toString(), sourceList);
}
} catch (Exception e) {
source = null;
......
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