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
update from master
[fanfix.git]
/
supported
/
BasicSupport.java
diff --git
a/supported/BasicSupport.java
b/supported/BasicSupport.java
index 56a3bb80cb6d51fe40a9c4d830e12cb275102d76..9b56f885d94a14ff1025b3833aa34209c48374dd 100644
(file)
--- a/
supported/BasicSupport.java
+++ b/
supported/BasicSupport.java
@@
-272,7
+272,14
@@
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());
+ if (meta.getPublisher() == null) {
+ 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
+354,9
@@
public abstract class BasicSupport {
Scanner scan = new Scanner(in);
scan.useDelimiter("\0");
try {
Scanner scan = new Scanner(in);
scan.useDelimiter("\0");
try {
+ if(!scan.hasNext())
+ throw new IOException("The given input was empty");
+
return new JSONObject(scan.next());
} catch (JSONException e) {
throw new IOException(e);
return new JSONObject(scan.next());
} catch (JSONException e) {
throw new IOException(e);