Fixed a bug in the update script with submodules of submodules.