Add main function and fire script from main call. Prevents script from running before it is entirely downloaded.

This commit is contained in:
Dan Schaper 2016-10-08 12:17:04 -07:00
parent 33745be745
commit 44170207ac

View file

@ -903,7 +903,7 @@ updateDialogs(){
}
######## SCRIPT ############
main() {
if [[ -f ${setupVars} ]];then
. ${setupVars}
@ -979,3 +979,6 @@ fi
echo ":::"
echo "::: The install log is located at: /etc/pihole/install.log"
echo "::: View the web interface at http://pi.hole/admin or http://${IPv4addr%/*}/admin"
}
main "$@"