Skip to content

Commit

Permalink
Explicitly use a range step of -1 (#38)
Browse files Browse the repository at this point in the history
This fixes a deprecation warning introduced in Elixir 1.18.0. Range.new/3 was added
in Elixir 1.12.0 according to documentation, so should be safe to use with the
versions declared to be supported by Memento.
  • Loading branch information
sax authored Dec 21, 2024
1 parent c9218ee commit f06bc68
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/memento/table/definition.ex
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ defmodule Memento.Table.Definition do
attributes =
attributes
|> Enum.count
|> Range.new(1)
|> Range.new(1, -1)
|> Enum.reverse
|> Enum.map(&:"$#{&1}")

Expand Down

0 comments on commit f06bc68

Please sign in to comment.