We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7a95a55 commit 661ffafCopy full SHA for 661ffaf
bin/tdb
@@ -249,8 +249,9 @@ fi
249
if [[ "$action" == 'list' ]]; then
250
echo -e "\x1B[2mListing $db_type backups in ${backup_folder_local}\x1B[0m"
251
(
252
- files=( "$backup_folder_local"/*.${db_type} "$backup_folder_local"/*.dump)
253
- [ -e "${files[0]}" ] || { echo "No $db_type backups found" >&2; exit 0; }
+ shopt -s nullglob
+ files=( "$backup_folder_local"/*.${db_type} "$backup_folder_local"/*.dump )
254
+ [ ${#files[@]} -eq 0 ] && { echo "No $db_type backups found" >&2; exit 0; }
255
256
printf "Name\t\tDate\t\tSize\n"
257
for f in "${files[@]}"; do
0 commit comments