diff --git a/bin/installbfa.sh b/bin/installbfa.sh
index 20927863dd7ffeb0b511bdb4863b402b5551794b..9d043a167fc33b72f090db292d42877840aff5b9 100755
--- a/bin/installbfa.sh
+++ b/bin/installbfa.sh
@@ -70,11 +70,15 @@ function web3install
         info "Initialising nodejs." &&
         runasownerof ~bfa npm init -y
     # nodejs package(s) that we need.
-    echo 'require("web3")' | runasownerof ~bfa nodejs 2>/dev/null && return
-    info "Installing nodejs module: web3 (will show many warnings)"
-    runasownerof ~bfa npm install web3
     info "Installing nodejs module: require"
     runasownerof ~bfa npm install require
+    if echo 'require("web3")' | runasownerof ~bfa nodejs 2>/dev/null
+    then
+        true
+    else
+    	info "Installing nodejs module: web3 (will show many warnings)"
+    	runasownerof ~bfa npm install web3
+    fi
 }
 
 function golanginstall
@@ -195,10 +199,10 @@ function userconfig
 
 function cronit
 {
-    if [ $( ( crontab -u bfa -l 2>/dev/null || true ) | grep -E "$BFAHOME/bin/cron.sh" | wc -l ) -eq 0 ]
+    if [ $( ( crontab -u bfa -l 2>/dev/null || true ) | grep -E "${BFAHOME#~/}/bin/cron.sh" | wc -l ) -eq 0 ]
     then
         info "Install crontab to start automatically upon reboot"
-        (( crontab -u bfa -l 2>/dev/null || true ) ; echo "@reboot $BFAHOME/bin/cron.sh" ) | crontab -u bfa -
+        (( crontab -u bfa -l 2>/dev/null || true ) ; echo "@reboot ${BFAHOME#~/}/bin/cron.sh" ) | crontab -u bfa -
     fi
 }