Browse files

Added check for required device key

  • Loading branch information...
1 parent 1aba4ac commit e0067c60c4b081d1646402e231c595737490cae8 @tomas tomas committed Sep 25, 2009
Showing with 5 additions and 1 deletion.
  1. +5 −1 platform/base
View
6 platform/base
@@ -140,7 +140,11 @@ function check_net_status {
# we could eventually use a different method for status checking
function check_status {
if [ "$post_method" == 'http' ]; then
- check_url="$check_url/devices/$device_key.xml"
+ if [ -n "$device_key" ]; then
+ check_url="$check_url/devices/$device_key.xml"
+ else
+ echo ' !! You need to enter your Device Key for HTTP Check!'
+ fi
fi
headers=`$getter -I $check_url`
status=`echo -e "$headers" | grep HTTP | sed -e 's/[^200|302|400|404|500]//g' -e 's/^0//'`

0 comments on commit e0067c6

Please sign in to comment.