logo

pleroma

My custom branche(s) on git.pleroma.social/pleroma/pleroma git clone https://hacktivis.me/git/pleroma.git
commit: 2ee8f4f0629b950349409d69395015369c45b633
parent ff663c0aeb765351017f34bbeda2f336b6d09e26
Author: Mark Felder <feld@feld.me>
Date:   Tue, 23 Jul 2024 09:43:41 -0400

Fix dialyzer error

lib/pleroma/application.ex:1:pattern_match The pattern can never match the type true.

Diffstat:

Achangelog.d/dialyzer5.skip0
Mconfig/test.exs2++
Mlib/pleroma/application.ex3+--
3 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/changelog.d/dialyzer5.skip b/changelog.d/dialyzer5.skip diff --git a/config/test.exs b/config/test.exs @@ -187,6 +187,8 @@ config :pleroma, Pleroma.Emoji.Loader, test_emoji: true config :pleroma, Pleroma.Web.RichMedia.Backfill, stream_out: Pleroma.Web.ActivityPub.ActivityPubMock +config :pleroma, Pleroma.Web.Plugs.HTTPSecurityPlug, enable: false + if File.exists?("./config/test.secret.exs") do import_config "test.secret.exs" else diff --git a/lib/pleroma/application.ex b/lib/pleroma/application.ex @@ -14,7 +14,6 @@ defmodule Pleroma.Application do @name Mix.Project.config()[:name] @version Mix.Project.config()[:version] @repository Mix.Project.config()[:source_url] - @compile_env Mix.env() def name, do: @name def version, do: @version @@ -53,7 +52,7 @@ defmodule Pleroma.Application do Pleroma.Config.Oban.warn() Config.DeprecationWarnings.warn() - if @compile_env != :test do + if Config.get([Pleroma.Web.Plugs.HTTPSecurityPlug, :enable], true) do Pleroma.Web.Plugs.HTTPSecurityPlug.warn_if_disabled() end