From: Roger Braun Date: Mon, 1 May 2017 16:07:50 +0000 (+0200) Subject: Also accept user id as feed topic. X-Git-Url: https://git.squeep.com/?a=commitdiff_plain;h=97d11dec0ee78d24fea398f23d123baf0111362a;p=akkoma Also accept user id as feed topic. --- diff --git a/lib/pleroma/web/websub/websub.ex b/lib/pleroma/web/websub/websub.ex index b279a5060..fc253b930 100644 --- a/lib/pleroma/web/websub/websub.ex +++ b/lib/pleroma/web/websub/websub.ex @@ -98,7 +98,7 @@ defmodule Pleroma.Web.Websub do end defp valid_topic(%{"hub.topic" => topic}, user) do - if topic == OStatus.feed_path(user) do + if topic == OStatus.feed_path(user) || topic == Pleroma.Web.Router.Helpers.o_status_url(Pleroma.Web.Endpoint, :feed_redirect, user.nickname) do {:ok, OStatus.feed_path(user)} else {:error, "Wrong topic requested, expected #{OStatus.feed_path(user)}, got #{topic}"}