1
0
Fork 0
mirror of https://framagit.org/framasoft/mobilizon.git synced 2024-12-23 08:22:50 +00:00
mobilizon/lib/service/guards.ex
Thomas Citharel 2198b2cb87
Allow to filter search by multiple tags
Signed-off-by: Thomas Citharel <tcit@tcit.fr>
2020-08-10 15:40:19 +02:00

9 lines
232 B
Elixir

defmodule Mobilizon.Service.Guards do
@moduledoc """
Various guards
"""
defguard is_valid_string?(value) when is_binary(value) and value != ""
defguard is_valid_list?(value) when is_list(value) and length(value) > 0
end