Commit 002dd1c3 authored by Peter van 't Hof's avatar Peter van 't Hof
Browse files

Added a better error handling on a missing reference.

parent 23bbd96e
......@@ -94,12 +94,12 @@ trait Reference extends Configurable {
)
}
//TODO: this become obsolete when index get autogenerated
//TODO: this become obsolete when index get auto generated
/** Check fasta file if file exist and index file are there */
def checkFasta(file: File): Unit = {
if (!Reference.checked.contains(file)) {
require(file.exists(), "Reference not found: " + file)
if (!file.exists()) BiopetQScript.addError(s"Reference not found: $file, species: $referenceSpecies, name: $referenceName, configValue: " + config("reference_fasta"))
if (dictRequired) Reference.requireDict(file)
if (faiRequired) Reference.requireFai(file)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment