diff options
author | Steven Fuchs <steven.fuchs@dockyard.com> | 2019-11-11 12:13:06 +0000 |
---|---|---|
committer | lain <lain@soykaf.club> | 2019-11-11 12:13:06 +0000 |
commit | 94627baa5cca524fe0c4f7043e25d71ed245626a (patch) | |
tree | 6b71d1a382fdb4dbcf2510397bbd59405afc79a4 /lib/pleroma/web/mongooseim | |
parent | 7438c177d9f57e8779b979ca553c3b501726efb3 (diff) | |
download | pleroma-94627baa5cca524fe0c4f7043e25d71ed245626a.tar.gz |
New rate limiter
Diffstat (limited to 'lib/pleroma/web/mongooseim')
-rw-r--r-- | lib/pleroma/web/mongooseim/mongoose_im_controller.ex | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/pleroma/web/mongooseim/mongoose_im_controller.ex b/lib/pleroma/web/mongooseim/mongoose_im_controller.ex index 6ed181cff..358600e7d 100644 --- a/lib/pleroma/web/mongooseim/mongoose_im_controller.ex +++ b/lib/pleroma/web/mongooseim/mongoose_im_controller.ex @@ -10,8 +10,8 @@ defmodule Pleroma.Web.MongooseIM.MongooseIMController do alias Pleroma.Repo alias Pleroma.User - plug(RateLimiter, :authentication when action in [:user_exists, :check_password]) - plug(RateLimiter, {:authentication, params: ["user"]} when action == :check_password) + plug(RateLimiter, [name: :authentication] when action in [:user_exists, :check_password]) + plug(RateLimiter, [name: :authentication, params: ["user"]] when action == :check_password) def user_exists(conn, %{"user" => username}) do with %User{} <- Repo.get_by(User, nickname: username, local: true) do |