Commit 63f04b31 authored by dtluna's avatar dtluna
Browse files

Fix typo

parent 4b4ece2c
......@@ -275,7 +275,7 @@ def get_user(user, params) do
if user do
{:ok, user}
else
{:error, "You need to specify screen_name of user_id"}
{:error, "You need to specify screen_name or user_id"}
end
end
end
......
......@@ -106,7 +106,7 @@ test "get a user by params" do
user1_result = {:ok, user1} = UserBuilder.insert(%{ap_id: "some id", email: "test@pleroma"})
{:ok, user2} = UserBuilder.insert(%{ap_id: "some other id", nickname: "testname2", email: "test2@pleroma"})
assert {:error, "You need to specify screen_name of user_id"} == TwitterAPI.get_user(nil, nil)
assert {:error, "You need to specify screen_name or user_id"} == TwitterAPI.get_user(nil, nil)
assert user1_result == TwitterAPI.get_user(nil, %{"user_id" => user1.id})
assert user1_result == TwitterAPI.get_user(nil, %{"screen_name" => user1.nickname})
assert user1_result == TwitterAPI.get_user(user1, nil)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment