From ad038ada452f040ad93380bb4339634faf9949a9 Mon Sep 17 00:00:00 2001 From: Pieter Verschaffelt Date: Tue, 13 Aug 2024 10:13:19 +0200 Subject: [PATCH] Properly write error and exit script when version tag not found --- scripts/build_database.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/scripts/build_database.sh b/scripts/build_database.sh index 8724f85..b53b103 100755 --- a/scripts/build_database.sh +++ b/scripts/build_database.sh @@ -358,8 +358,7 @@ extract_uniprot_version() { # Check if the version value is not empty if [[ -z "$version_value" ]]; then - echo "Version tag not found or empty in the XML file. Exiting" - exit 1 + errorAndExit "No valid version tag found for UniProt." fi # Convert YYYY_MM to YYYY.MM