From 7c00bd1ad57e15dd0d71125a7d0679154641b9ff Mon Sep 17 00:00:00 2001 From: Kerry Buckley Date: Thu, 29 Oct 2026 15:35:42 +0000 Subject: [PATCH] Correct documentation for Changeset.validate_required/3 Documentation states that the default value of `changeset.empty_values` is `[]` and `""`, but it is actually just `""`. --- lib/ecto/changeset.ex | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/ecto/changeset.ex b/lib/ecto/changeset.ex index 3cf456ec58..fa8eeecf5f 100644 --- a/lib/ecto/changeset.ex +++ b/lib/ecto/changeset.ex @@ -2574,7 +2574,7 @@ defmodule Ecto.Changeset do are required. If the value of a field is `nil` or matches any of the values - configured in `changeset.empty_values` (by default `[]` and `""`), + configured in `changeset.empty_values` (by default `""`), the changeset is marked as invalid, the field is removed from the changeset's changes, and an error is added. An error won't be added if the field already has an error.