Skip to content

Commit

Permalink
format lib/paper_trail/version_queries.ex
Browse files Browse the repository at this point in the history
  • Loading branch information
izelnakri committed Mar 26, 2021
1 parent 9f67f3c commit f9b881c
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/paper_trail/version_queries.ex
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,8 @@ defmodule PaperTrail.VersionQueries do
|> PaperTrail.RepoClient.repo().one
end

@spec get_version(model :: module, id :: pos_integer, options :: keyword | []) :: Version.t() | nil
@spec get_version(model :: module, id :: pos_integer, options :: keyword | []) ::
Version.t() | nil
def get_version(model, id, options) do
item_type = model |> Module.split() |> List.last()
last(version_query(item_type, id, options)) |> PaperTrail.RepoClient.repo().one
Expand Down

0 comments on commit f9b881c

Please sign in to comment.