From 944d72af5d3f0357d25a8275920d67645ee1b6f2 Mon Sep 17 00:00:00 2001 From: sigonasr2 Date: Wed, 10 Aug 2022 11:28:16 -0500 Subject: [PATCH] Corrected how to reach the API via token --- checkregistration.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/checkregistration.sh b/checkregistration.sh index 13e4030..7548cbf 100755 --- a/checkregistration.sh +++ b/checkregistration.sh @@ -1,5 +1,5 @@ cd /home/sigonasr2/GiteaMailNotifications -CURRENT=$(curl -s -D - -o /dev/null 'http://sig.projectdivar.com/api/v1/admin/users' -H 'accept: application/json' -H 'authorization: Basic $(cat .APIKEY)' | grep "X-Total-Count:") +CURRENT=$(curl -s -D - -o /dev/null 'http://sig.projectdivar.com/api/v1/admin/users?token='$(cat .APIKEY) -H 'accept: application/json' | grep "X-Total-Count:") PREVIOUS=$(cat registeredusers.data) if [ "$CURRENT" != "$PREVIOUS" ]; then ./notifyregistration.sh