Fixed #24008 -- ValidationError crashes with list of dicts

No, this isn't the same. This construct with `sum` flattens a list of lists.