check initial fetch is an integer

This commit is contained in:
Kai Hendry
2011-11-13 20:10:32 +01:00
parent ecb718a2cc
commit 28b86ee989

View File

@@ -10,7 +10,9 @@ then
exit 1 exit 1
fi fi
if ! twitter_total=$(curl -s "http://api.twitter.com/1/users/lookup.xml?screen_name=$1" | xmlstarlet sel -t -m "//users/user/statuses_count" -v .) twitter_total=$(curl -s "http://api.twitter.com/1/users/lookup.xml?screen_name=$1" | xmlstarlet sel -t -m "//users/user/statuses_count" -v .)
if ! test "$twitter_total" -gt 0
then then
echo Twitter API not working echo Twitter API not working
exit exit