diff --git a/prymer/primer3/primer3.py b/prymer/primer3/primer3.py index 59b712a..33c7ab0 100644 --- a/prymer/primer3/primer3.py +++ b/prymer/primer3/primer3.py @@ -402,10 +402,7 @@ def design(self, design_input: Primer3Input) -> Primer3Result: # noqa: C901 # Check for any errors. Typically, these are in error_lines, but also the results can # contain the PRIMER_ERROR key. if "PRIMER_ERROR" in primer3_results: - if "PRIMER_ERROR" in primer3_results: - raise ValueError("Primer3 failed: " + primer3_results["PRIMER_ERROR"]) - else: - raise ValueError("Primer3 failed") + raise ValueError("Primer3 failed: " + primer3_results["PRIMER_ERROR"]) match design_input.task: case DesignPrimerPairsTask(): # Primer pair design