89940d36f8
A better fix has been proposed upstream at https://github.com/rails/rails/pull/56283 but this should be fine in the meantime. ref: https://app.fizzy.do/5986089/cards/3188