Merge "Prevent bad grid configuration by making sure RestoreDbTask updates IDP correctly." into main