From 48c38ea62d00ae6b98fa04f606275edfb9f13341 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Carlos=20Sol=C3=ADs?= Date: Mon, 3 Feb 2025 17:38:13 +0000 Subject: [PATCH] fix: Tighten invalid file detection --- friendica-remove-invalid-photos.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/friendica-remove-invalid-photos.sh b/friendica-remove-invalid-photos.sh index d64fe99..0376ffc 100755 --- a/friendica-remove-invalid-photos.sh +++ b/friendica-remove-invalid-photos.sh @@ -51,7 +51,7 @@ do echo "$id $avatar" sudo -u $user curl "$avatar" -s -o "$k_photo" #If the file is a valid picture (not empty, not text) - if file "$k_photo" | grep -q -v -e "text" -e "Empty" + if file "$k_photo" | grep -q -v -e "text" -e "empty" -e "symbolic link" -e "directory" then #Also fetch for thumb/micro and resize #As the photo is the largest version we have, we will use it as the base, and leave it last to convert