correction suppression mattermost

This commit is contained in:
2026-08-09 21:08:21 +02:00
parent 88d3bf72b9
commit 9292ce8a91
+6 -6
View File
@@ -297,15 +297,15 @@ searchDestroy() {
####################################################################################################################
if [ "${DOMAINE_EN_COURS}" = "${domain}" ]
then
REP_SEARCH=$(searchMattermost $REP_SEARCH_DESTROY)
if [ ! -z ${REP_SEARCH} ]
MM_USER_ID=$(searchMattermost $REP_SEARCH_DESTROY)
if [ ! -z ${MM_USER_ID} ]
then
echo -e "${RED} suppression de ${REP_SEARCH_DESTROY} trouvé dans mattermost ${NC}"
status_del=$(curl --request DELETE \
-w "%{status}" \
status_del=$(curl -s --request DELETE \
--header 'Accept: application/json' \
-H "Authorization: Bearer ${mattermost_token}" \
"${URL_AGORA_API}/api/v4/users/${REP_SEARCH_DESTROY}")
if [ "${status_del}" -eq "200" ]
"${URL_AGORA_API}/api/v4/users/${MM_USER_ID}")
if [ "$(echo ${status_del} | jq -r .status)" -eq "200" ]
then
printKazMsg "Suppresion ok"
else