This commit is contained in:
Niko Kurtti 2017-09-18 13:45:22 +00:00 committed by GitHub
commit bb2a48257c

View file

@ -335,8 +335,11 @@ if [ "${CHECKUPDATE}" = "yes" -a "${AUTOUPDATE}" = "no" ]; then
fi fi
if [ "${PUBLIC}" = "no" -a -z "$TOKEN" ]; then if [ "${PUBLIC}" = "no" -a -z "$TOKEN" ]; then
TO_SOURCE="$(dirname "$0")/extras/get-plex-token" declare -f getPlexToken > /dev/null
[ -f "$TO_SOURCE" ] && source $TO_SOURCE if [ $? -ne 0 ]; then
error "getPlexToken() function missing, check that it its sourced correctly"
exit 3
fi
if ! getPlexToken; then if ! getPlexToken; then
error "Unable to get Plex token, falling back to public release" error "Unable to get Plex token, falling back to public release"
PUBLIC="yes" PUBLIC="yes"