git://git.nikiroo.be
/
fanfix.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch 'subtree'
[fanfix.git]
/
src
/
be
/
nikiroo
/
fanfix
/
supported
/
BasicSupport.java
diff --git
a/src/be/nikiroo/fanfix/supported/BasicSupport.java
b/src/be/nikiroo/fanfix/supported/BasicSupport.java
index f1635589bfd70b0dca80b5972dcfd241bda895f8..bcfcca1bdbb16cfd3bd8849e8fdb2bfb55a22de0 100644
(file)
--- a/
src/be/nikiroo/fanfix/supported/BasicSupport.java
+++ b/
src/be/nikiroo/fanfix/supported/BasicSupport.java
@@
-12,6
+12,7
@@
import java.util.Map;
import java.util.Scanner;
import java.util.Map.Entry;
import java.util.Scanner;
import java.util.Map.Entry;
+import org.json.JSONException;
import org.json.JSONObject;
import org.jsoup.helper.DataUtil;
import org.jsoup.nodes.Document;
import org.json.JSONObject;
import org.jsoup.helper.DataUtil;
import org.jsoup.nodes.Document;
@@
-271,7
+272,12
@@
public abstract class BasicSupport {
pg.setProgress(30);
Story story = new Story();
pg.setProgress(30);
Story story = new Story();
+
MetaData meta = getMeta();
MetaData meta = getMeta();
+ meta.setType(getType().toString());
+ meta.setSource(getType().getSourceName());
+ meta.setPublisher(getType().getSourceName());
+
if (meta.getCreationDate() == null
|| meta.getCreationDate().trim().isEmpty()) {
meta.setCreationDate(bsHelper
if (meta.getCreationDate() == null
|| meta.getCreationDate().trim().isEmpty()) {
meta.setCreationDate(bsHelper
@@
-347,6
+353,8
@@
public abstract class BasicSupport {
scan.useDelimiter("\0");
try {
return new JSONObject(scan.next());
scan.useDelimiter("\0");
try {
return new JSONObject(scan.next());
+ } catch (JSONException e) {
+ throw new IOException(e);
} finally {
scan.close();
}
} finally {
scan.close();
}