Skip to content

Commit

Permalink
Update check.sh
Browse files Browse the repository at this point in the history
  • Loading branch information
acacia233 authored Dec 17, 2022
1 parent 0c2cde6 commit df45262
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions check.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2081,7 +2081,7 @@ function MediaUnlockTest_ESPNPlus() {
local is403=$(echo $TokenContent | grep '403 ERROR')

if [ -n "$isBanned" ] || [ -n "$is403" ]; then
echo -n -e "\r ESPN+:${Font_SkyBlue}[Sponsored by Jam]${Font_Suffix}\t\t\t${Font_Red}No${Font_Suffix}\n"
echo -n -e "\r ESPN+:${Font_SkyBlue}[Sponsored by Jam]${Font_Suffix}\t\t${Font_Red}No${Font_Suffix}\n"
return
fi

Expand All @@ -2091,17 +2091,17 @@ function MediaUnlockTest_ESPNPlus() {
local tmpresult=$(curl -${1} --user-agent "${UA_Browser}" -X POST -sSL --max-time 10 "https://espn.api.edge.bamgrid.com/graph/v1/device/graphql" -H "authorization: ZXNwbiZicm93c2VyJjEuMC4w.ptUt7QxsteaRruuPmGZFaJByOoqKvDP2a5YkInHrc7c" -d "$espncontent" 2>&1)

if [[ "$tmpresult" == "curl"* ]]; then
echo -n -e "\r ESPN+:${Font_SkyBlue}[Sponsored by Jam]${Font_Suffix}\t\t\t${Font_Red}Failed (Network Connection)${Font_Suffix}\n"
echo -n -e "\r ESPN+:${Font_SkyBlue}[Sponsored by Jam]${Font_Suffix}\t\t${Font_Red}Failed (Network Connection)${Font_Suffix}\n"
return
fi
local region=$(echo $tmpresult | python -m json.tool 2>/dev/null | grep 'countryCode' | cut -f4 -d'"')
local inSupportedLocation=$(echo $tmpresult | python -m json.tool 2>/dev/null | grep 'inSupportedLocation' | awk '{print $2}' | cut -f1 -d',')

if [[ "$region" == "US" ]] && [[ "$inSupportedLocation" == "true" ]]; then
echo -n -e "\r ESPN+:${Font_SkyBlue}[Sponsored by Jam]${Font_Suffix}\t\t\t${Font_Green}Yes${Font_Suffix}\n"
echo -n -e "\r ESPN+:${Font_SkyBlue}[Sponsored by Jam]${Font_Suffix}\t\t${Font_Green}Yes${Font_Suffix}\n"
return
else
echo -n -e "\r ESPN+:${Font_SkyBlue}[Sponsored by Jam]${Font_Suffix}\t\t\t${Font_Red}No${Font_Suffix}\n"
echo -n -e "\r ESPN+:${Font_SkyBlue}[Sponsored by Jam]${Font_Suffix}\t\t${Font_Red}No${Font_Suffix}\n"
return
fi

Expand Down

0 comments on commit df45262

Please sign in to comment.