Any particular reason why this is only done if mapsToRestore is set?