Pleroma.Web.ActivityPub.Builder: fix dialyzer error
lib/pleroma/web/activity_pub/builder.ex:115:pattern_match The pattern can never match the type. Pattern: _emojo = %{:file => _path} Type: nil | binary()
This commit is contained in:
parent
3fbe8ada93
commit
2062e126f1
|
@ -51,12 +51,12 @@ def reload do
|
|||
end
|
||||
|
||||
@doc "Returns the path of the emoji `name`."
|
||||
@spec get(String.t()) :: String.t() | nil
|
||||
@spec get(String.t()) :: Emoji.t() | nil
|
||||
def get(name) do
|
||||
name = maybe_strip_name(name)
|
||||
|
||||
case :ets.lookup(@ets, name) do
|
||||
[{_, path}] -> path
|
||||
[{_, emoji}] -> emoji
|
||||
_ -> nil
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue