Skip to content

Commit

Permalink
https://github.com/bonfire-networks/bonfire-app/issues/900
Browse files Browse the repository at this point in the history
  • Loading branch information
mayel committed Dec 31, 2024
1 parent 8667542 commit d695892
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/types.ex
Original file line number Diff line number Diff line change
Expand Up @@ -221,8 +221,8 @@ defmodule Bonfire.Common.Types do
iex> uids("invalid_id")
[]
"""
def uids(objects) do
objects |> List.wrap() |> List.flatten() |> Enum.map(&uid/1) |> Enums.filter_empty([])
def uids(objects, fallback \\ []) do
objects |> List.wrap() |> List.flatten() |> Enum.map(&uid/1) |> Enums.filter_empty(fallback)
end

def uid_or_uids(objects) when is_list(objects) do
Expand Down

0 comments on commit d695892

Please sign in to comment.