Limit the amount of records in the list

Needs to be replaced with pagination
This commit is contained in:
Claudio Ortolina
2024-09-14 14:24:42 +01:00
parent 51d18f37bf
commit e1ab16a5fd
+3 -1
View File
@@ -18,7 +18,9 @@ defmodule MusicLibrary.Records do
""" """
def list_records do def list_records do
Repo.all(Record) Record
|> limit(10)
|> Repo.all()
end end
@doc """ @doc """