diff --git a/lib/pleroma/application.ex b/lib/pleroma/application.ex index 02dd39939..fe94b56f4 100644 --- a/lib/pleroma/application.ex +++ b/lib/pleroma/application.ex @@ -202,7 +202,10 @@ defmodule Pleroma.Application do end defp chat_child(true) do - [Pleroma.Web.ChatChannel.ChatChannelState] + [ + Pleroma.Web.ChatChannel.ChatChannelState, + {Phoenix.PubSub, [name: Pleroma.PubSub, adapter: Phoenix.PubSub.PG2]} + ] end defp chat_child(_), do: [] diff --git a/lib/pleroma/web/web.ex b/lib/pleroma/web/web.ex index 4f9281851..c319d223c 100644 --- a/lib/pleroma/web/web.ex +++ b/lib/pleroma/web/web.ex @@ -177,7 +177,7 @@ defmodule Pleroma.Web do def channel do quote do # credo:disable-for-next-line Credo.Check.Consistency.MultiAliasImportRequireUse - use Phoenix.Channel + import Phoenix.Channel import Pleroma.Web.Gettext end end diff --git a/test/support/channel_case.ex b/test/support/channel_case.ex index d63a0f06b..114184a9f 100644 --- a/test/support/channel_case.ex +++ b/test/support/channel_case.ex @@ -22,7 +22,7 @@ defmodule Pleroma.Web.ChannelCase do using do quote do # Import conveniences for testing with channels - use Phoenix.ChannelTest + import Phoenix.ChannelTest use Pleroma.Tests.Helpers # The default endpoint for testing