aboutsummaryrefslogtreecommitdiff
path: root/lib/pleroma/web/common_api/utils.ex
diff options
context:
space:
mode:
authorIvan Tashkinov <ivant.business@gmail.com>2019-04-02 14:05:34 +0300
committerIvan Tashkinov <ivant.business@gmail.com>2019-04-02 14:05:34 +0300
commit37925cbe78b7fc73f28cc85ffcf1e16fb00f7a24 (patch)
tree2e3f848e697426f4b79d8e02a2ba20df12368ca9 /lib/pleroma/web/common_api/utils.ex
parent590c935d95f0ea4fb65994027a88a0623527af88 (diff)
parent091baf93169895c62418ccee81b80d00416aaa56 (diff)
downloadpleroma-37925cbe78b7fc73f28cc85ffcf1e16fb00f7a24.tar.gz
Merge remote-tracking branch 'remotes/upstream/develop' into twitter_oauth
# Conflicts: # lib/pleroma/web/oauth/oauth_controller.ex # lib/pleroma/web/router.ex
Diffstat (limited to 'lib/pleroma/web/common_api/utils.ex')
-rw-r--r--lib/pleroma/web/common_api/utils.ex4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/pleroma/web/common_api/utils.ex b/lib/pleroma/web/common_api/utils.ex
index f596f703b..40cea3090 100644
--- a/lib/pleroma/web/common_api/utils.ex
+++ b/lib/pleroma/web/common_api/utils.ex
@@ -31,7 +31,7 @@ defmodule Pleroma.Web.CommonAPI.Utils do
def get_replied_to_activity(""), do: nil
def get_replied_to_activity(id) when not is_nil(id) do
- Repo.get(Activity, id)
+ Activity.get_by_id(id)
end
def get_replied_to_activity(_), do: nil
@@ -275,7 +275,7 @@ defmodule Pleroma.Web.CommonAPI.Utils do
end
def confirm_current_password(user, password) do
- with %User{local: true} = db_user <- Repo.get(User, user.id),
+ with %User{local: true} = db_user <- User.get_by_id(user.id),
true <- Pbkdf2.checkpw(password, db_user.password_hash) do
{:ok, db_user}
else