Apply suggestion to lib/pleroma/http/request_builder.ex
authorAlexander Strizhakov <alex.strizhakov@gmail.com>
Tue, 3 Mar 2020 09:46:53 +0000 (09:46 +0000)
committerAlexander Strizhakov <alex.strizhakov@gmail.com>
Tue, 3 Mar 2020 09:46:53 +0000 (09:46 +0000)
lib/pleroma/http/request_builder.ex

index 491acd0f9fbcc67fb282efdf23ea1efa3ab1f50d..046741d998e67b401fbc16fbcb012ff63aee1e90 100644 (file)
@@ -35,7 +35,7 @@ defmodule Pleroma.HTTP.RequestBuilder do
   def headers(request, headers) do
     headers_list =
       if Pleroma.Config.get([:http, :send_user_agent]) do
-        headers ++ [{"user-agent", Pleroma.Application.user_agent()}]
+        [{"user-agent", Pleroma.Application.user_agent()} | headers]
       else
         headers
       end