Remove a rather useless eval in the chat/answer example

This commit is contained in:
Alexei Sorokin 2016-08-22 01:23:27 +03:00
parent 2d96423021
commit 788e3a9c7f
1 changed files with 1 additions and 1 deletions

View File

@ -36,7 +36,7 @@ if [[ "$string" == *http*://* ]]; then
sed -e '/https*:\/\//!d' ./frs.txt | sed -n "$(random "$amount")p"
img="$(printf "%s\n" "$string" | sed -ne 's|.*\(https*://[^ \"()<>]*\).*|\1|g;1p')"
ns="$(printf "%s\n" "$string" | sed -e "s|$img||g")"
cl="$(wget --spider -S $(eval printf '%s\n' '$img') 2>&1)"
cl="$(wget --spider -S "$img" 2>&1)"
if [[ $(printf "%s\n" "$cl" | sed -e '/Content-Type/!d;/image\//!d') ]]; then
#echo 'posting'
printf "%s\n" "$img $from" >> ../data/pictures