Skip to content

Commit

Permalink
Cosmetic fix - showing error even it wasn't there when creating repos…
Browse files Browse the repository at this point in the history
…itory.
  • Loading branch information
igorpecovnik committed Jan 20, 2018
1 parent 9531d1b commit 5ad2a94
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions lib/general.sh
Expand Up @@ -476,9 +476,11 @@ addtorepo()
(aptly repo list -config=../config/aptly.conf) | egrep packages

# remove debs if no errors found
if [[ $errors -eq 0 && "$2" == "delete" ]]; then
display_alert "Purging incoming debs" "all" "ext"
find ${POT} -name "*.deb" -type f -delete
if [[ $errors -eq 0 ]]; then
if [[ "$2" == "delete" ]]; then
display_alert "Purging incoming debs" "all" "ext"
find ${POT} -name "*.deb" -type f -delete
fi
else
display_alert "There were some problems $err_txt" "leaving incoming directory intact" "err"
fi
Expand Down

0 comments on commit 5ad2a94

Please sign in to comment.