move wait_release into conditional block

This commit is contained in:
benniekiss 2024-07-05 14:56:00 +00:00 committed by benniekiss
parent 41c22492d2
commit 2b1dcdb5a7

View file

@ -143,7 +143,6 @@ wait_release() {
download() {
setup_api
wait_release
(
mkdir -p $RELEASE_DIR
cd $RELEASE_DIR
@ -151,6 +150,7 @@ download() {
echo "Downloading the latest release"
api GET repos/$REPO/releases/latest > $TMP_DIR/assets.json
elif test ${DOWNLOAD_lATEST} == "false"; then
wait_release
echo "Downloading tagged release ${TAG}"
api GET repos/$REPO/releases/tags/$TAG > $TMP_DIR/assets.json
fi