diff --git a/plexupdate.sh b/plexupdate.sh index 90de9fc..dd336a9 100755 --- a/plexupdate.sh +++ b/plexupdate.sh @@ -335,6 +335,11 @@ if [ "${CHECKUPDATE}" = "yes" -a "${AUTOUPDATE}" = "no" ]; then fi if [ "${PUBLIC}" = "no" -a -z "$TOKEN" ]; then + declare -f getPlexToken > /dev/null + if [ $? -ne 0 ]; then + error "getPlexToken() function missing, check that it its sourced correctly" + exit 3 + fi if ! getPlexToken; then error "Unable to get Plex token, falling back to public release" PUBLIC="yes"