Let a chance for other parsers on audioTagParser error

As done in all other parsers, eventually falling back in the end to the
genericParser which creates a minimal index entry.
pull/167/head
luccioman 7 years ago
parent 9e5846a26e
commit 978e2be95b

@ -314,27 +314,7 @@ public class audioTagParser extends AbstractParser implements Parser {
}; };
return docs; return docs;
} catch (final Exception e) { } catch (final Exception e) {
// return a generic document as default throw new Parser.Failure("Unexpected error while parsing audio file. " + e.getMessage(), location);
docs = new Document[]{new Document(
location,
mimeType,
charset,
this,
null,
null,
singleList(filename), // title
null, // author
location.getHost(),
null,
null,
0.0d, 0.0d,
location.toTokens(),
null,
null,
null,
false,
new Date()
)};
} finally { } finally {
if (tempFile != null) { if (tempFile != null) {
tempFile.delete(); tempFile.delete();
@ -344,7 +324,6 @@ public class audioTagParser extends AbstractParser implements Parser {
*/ */
} }
} }
return docs;
} }
/** /**

Loading…
Cancel
Save