diff --git a/wled b/wled index b46f8b9..c0e89ff 100755 --- a/wled +++ b/wled @@ -70,10 +70,15 @@ current_brightness() { sed -n 's/.*"state"[[:space:]]*:[[:space:]]*{[^}]*"bri"[[:space:]]*:[[:space:]]*\([0-9]\{1,3\}\).*/\1/p' } +if test $# -eq 0; then + print_help + exit 0 +fi + # Parse instance argument and store hostnames. while test $# -gt 0; do case "$1" in - ""|-h|--help) # Missing instance parameter. + -h|--help) print_help exit 0 ;;