From a54df36c2fb93c56136052794debd0512639205c Mon Sep 17 00:00:00 2001 From: poka Date: Wed, 18 Dec 2019 16:35:29 +0100 Subject: [PATCH] Fix sms_abo memberid --- shell/sms_ABO.sh | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/shell/sms_ABO.sh b/shell/sms_ABO.sh index e3c77fb..28ff437 100755 --- a/shell/sms_ABO.sh +++ b/shell/sms_ABO.sh @@ -19,18 +19,14 @@ sms_INIT_ACCOUNT "$PHONE" case "$SERVICE" in ON) - log "Abonnement Kalkun" - if [[ "$MEMBER" != "" ]]; then - add_contact $PHONE $MEMBERUID && log "${c_green}Contact has been added to database$c_" || log "${c_red}Contact can't be added to database$c_"; - sms_SEND "$PHONE" "$MEMBER votre inscription annuaire est active" - fi + log "Abonnement Kalkun" + add_contact $PHONE $MEMBER && log "${c_green}Contact has been added to database$c_" || log "${c_red}Contact can't be added to database$c_"; + sms_SEND "$PHONE" "$MEMBER votre inscription annuaire est active" ;; OFF) log "Retrait Kalkun" - if [[ $MEMBER ]]; then - rm_contact $PHONE $MEMBERUID && log "${c_green}Contact has been deleted from database$c_" || log "${c_red}Contact can't be deleted database$c_"; - sms_SEND "$PHONE" "$MEMBER retrait annuaire prise en compte..." - fi + rm_contact $PHONE $MEMBER && log "${c_green}Contact has been deleted from database$c_" || log "${c_red}Contact can't be deleted database$c_"; + sms_SEND "$PHONE" "$MEMBER retrait annuaire prise en compte..." ;; MARCHE)