mirror of
https://github.com/Athou/commafeed.git
synced 2026-03-21 21:37:29 +00:00
tweak feed fetching
This commit is contained in:
@@ -30,7 +30,6 @@ public class FeedParser {
|
||||
feed.setLastUpdated(Calendar.getInstance().getTime());
|
||||
|
||||
try {
|
||||
xml = balanceTags(xml);
|
||||
SyndFeed rss = new SyndFeedInput().build(new StringReader(xml));
|
||||
|
||||
List<SyndEntry> items = rss.getEntries();
|
||||
@@ -46,7 +45,6 @@ public class FeedParser {
|
||||
feed.getEntries().add(entry);
|
||||
}
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
throw new FeedException(String.format(
|
||||
"Could not parse feed from %s : %s", feedUrl,
|
||||
e.getMessage()), e);
|
||||
@@ -72,11 +70,6 @@ public class FeedParser {
|
||||
return content;
|
||||
}
|
||||
|
||||
private String balanceTags(String xml) throws Exception {
|
||||
// TODO close tags
|
||||
return xml;
|
||||
}
|
||||
|
||||
private String handleContent(String content) {
|
||||
org.jsoup.nodes.Document doc = Jsoup.parse(content, "UTF-8");
|
||||
doc.select("a").attr("target", "_blank");
|
||||
|
||||
Reference in New Issue
Block a user