Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def get_by(module, params) do
- Enum.find all(module), fn map ->
- Enum.all?(params, fn {key, val} -> Map.get(map, key) == val end)
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement