Cleaned up the updateSubmodules script so it works reliably