Commit graph

8 commits

Author SHA1 Message Date
Mark Felder cfc8d7aade IPFS uploader: dialyzer fixes
lib/pleroma/uploaders/ipfs.ex:43:no_return
Function put_file/1 has no local return.
________________________________________________________________________________
lib/pleroma/uploaders/ipfs.ex:49:call
The function call will not succeed.

Pleroma.HTTP.post(
  binary(),
  _mp :: %Tesla.Multipart{
    :boundary => binary(),
    :content_type_params => [binary()],
    :parts => [
      %Tesla.Multipart.Part{
        :body => binary(),
        :dispositions => [any()],
        :headers => [any()]
      },
      ...
    ]
  },
  [],
  [{:params, [{:"cid-version", <<49>>}]}]
)

will never return since the success typing is:
(binary(), binary(), [{binary(), binary()}], Keyword.t()) ::
  {:error, _}
  | {:ok,
     %Tesla.Env{
       :__client__ => %Tesla.Client{
         :adapter => nil | {_, _} | {_, _, _},
         :fun => _,
         :post => [any()],
         :pre => [any()]
       },
       :__module__ => atom(),
       :body => _,
       :headers => [{_, _}],
       :method => :delete | :get | :head | :options | :patch | :post | :put | :trace,
       :opts => [{_, _}],
       :query => [{_, _}],
       :status => nil | integer(),
       :url => binary()
     }}

and the contract is
(Pleroma.HTTP.Request.url(), String.t(), Pleroma.HTTP.Request.headers(), :elixir.keyword()) ::
  {:ok, Tesla.Env.t()} | {:error, any()}
2024-05-30 15:14:27 -04:00
Mark Felder 2950397d47 Fix following redirects with Finch 2023-12-29 00:50:50 -05:00
lain e853cfe7c3 Revert "Merge branch 'copyright-bump' into 'develop'"
This reverts merge request !3825
2023-01-02 20:38:50 +00:00
marcin mikołajczak 10886eeaa2 Bump copyright year
Signed-off-by: marcin mikołajczak <git@mkljczk.pl>
2023-01-01 12:13:06 +01:00
Alexander Strizhakov 4121bca895 expanding WebFinger 2022-11-03 09:48:24 -04:00
Sean King 17aa3644be
Copyright bump for 2022 2022-02-25 23:11:42 -07:00
Haelwenn (lanodan) Monnier c4439c630f
Bump Copyright to 2021
grep -rl '# Copyright © .* Pleroma' * | xargs sed -i 's;Copyright © .* Pleroma .*;Copyright © 2017-2021 Pleroma Authors <https://pleroma.social/>;'
2021-01-13 07:49:50 +01:00
Alexander Strizhakov 0374df1d12
other files consistency 2020-10-13 16:38:19 +03:00
Renamed from lib/pleroma/http/http.ex (Browse further)