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

pull/770/head
Dan Schaper 8 years ago
parent 33745be745
commit 44170207ac

@ -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 "$@"
Loading…
Cancel
Save