commit: 28af5e3bd7073980465c1f6c1b2f6019c4a45e4f
parent a24322fccea9e4b095e084bfe631cf4a0a610ba9
Author: Mark Felder <feld@feld.me>
Date: Fri, 26 Jan 2024 17:21:48 -0500
TwitterAPI.UtilController: fix dialyzer errors
lib/pleroma/web/twitter_api/controllers/util_controller.ex:300:pattern_match
The pattern can never match the type.
Pattern:
{:error, :no_such_alias}
Type:
{:not_found, nil}
lib/pleroma/web/twitter_api/controllers/util_controller.ex:304:pattern_match
The pattern can never match the type.
Pattern:
{:error, _error}
Type:
{:not_found, nil}
Diffstat:
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/pleroma/web/twitter_api/controllers/util_controller.ex b/lib/pleroma/web/twitter_api/controllers/util_controller.ex
@@ -319,7 +319,7 @@ defmodule Pleroma.Web.TwitterAPI.UtilController do
user = User.get_cached_by_nickname(nickname)
if user == nil do
- {:not_found, nil}
+ {:error, :not_found}
else
{:ok, user}
end