diff --git a/CHANGELOG.md b/CHANGELOG.md index fc36f6b..fa2e90d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,32 @@ ## Unreleased +## [0.26.1] - 2024-08-19 + +### Fixed + +- Fixed allowed operators for `Ecto.Enum` fields in Ecto 3.12. +- Fixed type expansion when passing values with shortened syntax to + `Flop.Filter.expand_type/1`. +- Updated documentation example for setting `ecto_type` to parameterized types. + +### Upgrade Guide + +If you pass a parameterized type as `ecto_type` option, ensure that you use +`Ecto.ParameterizedType.init/2` instead of using the tuple representation as +suggested in the documentation before. The tuple representation is an internal +representation of Ecto and was changed in Ecto 3.12. + +```diff +[ +- ecto_type: {:parameterized, Ecto.Enum, Ecto.Enum.init(values: [:one, :two])} ++ ecto_type: Ecto.ParameterizedType.init(Ecto.Enum, values: [:one, :two]) +] +``` + +For `Ecto.Enum` specifically, you can also use the short syntax +`{:ecto_enum, [:one, :two]}`. + ## [0.26.0] - 2024-08-18 ### Removed diff --git a/README.md b/README.md index 13f3097..2b7a410 100644 --- a/README.md +++ b/README.md @@ -39,7 +39,7 @@ file: ```elixir def deps do [ - {:flop, "~> 0.26.0"} + {:flop, "~> 0.26.1"} ] end ``` diff --git a/mix.exs b/mix.exs index a23a3d7..542e5d9 100644 --- a/mix.exs +++ b/mix.exs @@ -2,7 +2,7 @@ defmodule Flop.MixProject do use Mix.Project @source_url "https://github.com/woylie/flop" - @version "0.26.0" + @version "0.26.1" def project do [