- @Override
- protected String getSubject(URL source, InputStream in) throws IOException {
- String tag = getInfoTag(source, "SUBJECT");
- if (tag != null) {
- return tag;
- }
-
- return super.getSubject(source, in);
- }
-
- @Override
- protected String getLang(URL source, InputStream in) throws IOException {
- String tag = getInfoTag(source, "LANG");
- if (tag != null) {
- return tag;
- }
-
- return super.getLang(source, in);
- }
-
- @Override
- protected String getPublisher(URL source, InputStream in)
- throws IOException {
- String tag = getInfoTag(source, "PUBLISHER");
- if (tag != null) {
- return tag;
- }
-
- return super.getPublisher(source, in);
- }
-
- @Override
- protected String getUuid(URL source, InputStream in) throws IOException {
- String tag = getInfoTag(source, "UUID");
- if (tag != null) {
- return tag;
- }
-
- return super.getUuid(source, in);
- }
-
- @Override
- protected String getLuid(URL source, InputStream in) throws IOException {
- String tag = getInfoTag(source, "LUID");
- if (tag != null) {
- return tag;
- }
-
- return super.getLuid(source, in);
- }
-
- @Override
- protected List<String> getTags(URL source, InputStream in)
- throws IOException {
- List<String> tags = super.getTags(source, in);
-
- String tt = getInfoTag(source, "TAGS");
- if (tt != null) {
- for (String tag : tt.split(",")) {
- tags.add(tag.trim());
+ // Some old .info files don't have those now required fields...
+ String test = meta.getTitle() == null ? "" : meta.getTitle();
+ test += meta.getAuthor() == null ? "" : meta.getAuthor();
+ test += meta.getDate() == null ? "" : meta.getDate();
+ test += meta.getUrl() == null ? "" : meta.getUrl();
+ if (test.isEmpty()) {
+ MetaData superMeta = super.getMeta();
+ if (meta.getTitle() == null || meta.getTitle().isEmpty()) {
+ meta.setTitle(superMeta.getTitle());