Merge branch 'develop' of https://git.pleroma.social/pleroma/pleroma into develop
authorsadposter <hannah+pleroma@coffee-and-dreams.uk>
Fri, 8 May 2020 13:12:33 +0000 (14:12 +0100)
committersadposter <hannah+pleroma@coffee-and-dreams.uk>
Fri, 8 May 2020 13:12:33 +0000 (14:12 +0100)
1  2 
config/config.exs
lib/mix/tasks/pleroma/activity.ex
lib/mix/tasks/pleroma/user.ex
lib/pleroma/web/nodeinfo/nodeinfo_controller.ex
priv/static/index.html
priv/static/sw-pleroma.js

Simple merge
index e03966e18da4782879c8f211b852a3450bba014f,0000000000000000000000000000000000000000..b4ab2f7df8408ca0067e4db22db74d86365c6c66
mode 100644,000000..100644
--- /dev/null
@@@ -1,23 -1,0 +1,24 @@@
 +# Pleroma: A lightweight social networking server
 +# Copyright © 2017-2018 Pleroma Authors <https://pleroma.social/>
 +# SPDX-License-Identifier: AGPL-3.0-only
 +
 +defmodule Mix.Tasks.Pleroma.Activity do
 +  alias Pleroma.Activity
 +  require Logger
 +  import Mix.Pleroma
 +  use Mix.Task
 +
 +  @shortdoc "A collection of activity debug tasks"
 +  @moduledoc """
 +   A collection of activity related tasks
 +
 +   mix pleroma.activity get <id>
 +  """
 +  def run(["get", id | _rest]) do
 +    start_pleroma()
++
 +    id
 +    |> Activity.get_by_id()
 +    |> IO.inspect()
 +  end
 +end
index d8400662d3fafbcb4bf5d957a80b4969673a6e2f,da140ac86d895ca18653f39f505408346b58b8b8..74cf50f04739be76923fbdcbbf73759497c614ef
@@@ -333,35 -336,6 +336,39 @@@ defmodule Mix.Tasks.Pleroma.User d
      end
    end
  
-        user
-        |> User.update_changeset(%{"email" => email})
-        |> User.update_and_set_cache()
-        shell_info("#{nickname}'s email updated")
 +  def run(["change_email", nickname, email]) do
 +    start_pleroma()
++
 +    with %User{} = user <- User.get_cached_by_nickname(nickname) do
-     |> IO.inspect
++      user
++      |> User.update_changeset(%{"email" => email})
++      |> User.update_and_set_cache()
++
++      shell_info("#{nickname}'s email updated")
 +    end
 +  end
 +
 +  def run(["show", nickname]) do
 +    start_pleroma()
++
 +    nickname
 +    |> User.get_cached_by_nickname()
-        user
-        |> Pleroma.Emails.UserEmail.account_confirmation_email()
-        |> IO.inspect
-        |> Pleroma.Emails.Mailer.deliver!()
-        shell_info("#{nickname}'s email sent")
++    |> IO.inspect()
 +  end
 +
 +  def run(["send_confirmation", nickname]) do
 +    start_pleroma()
++
 +    with %User{} = user <- User.get_cached_by_nickname(nickname) do
-   
++      user
++      |> Pleroma.Emails.UserEmail.account_confirmation_email()
++      |> IO.inspect()
++      |> Pleroma.Emails.Mailer.deliver!()
++
++      shell_info("#{nickname}'s email sent")
 +    end
 +  end
 +
    def run(["toggle_confirmed", nickname]) do
      start_pleroma()
  
index e4396da319c3ba3d1c938a6b0b164b5efe69302d,721b599d4b0df32a3d318e6e6cc68dcc28efc47b..b9c12374cb9e8d4239436ca27a1fd3f648488018
@@@ -42,47 -37,9 +37,10 @@@ defmodule Pleroma.Web.Nodeinfo.Nodeinfo
      staff_accounts =
        User.all_superusers()
        |> Enum.map(fn u -> u.ap_id end)
 +      |> Enum.filter(fn u -> not Enum.member?(Config.get([:instance, :staff_transparency]), u) end)
  
-     federation_response =
-       if Config.get([:instance, :mrf_transparency]) do
-         {:ok, data} = MRF.describe()
-         data
-         |> Map.merge(%{quarantined_instances: quarantined})
-       else
-         %{}
-       end
-       |> Map.put(:enabled, Config.get([:instance, :federating]))
-     features =
-       [
-         "pleroma_api",
-         "mastodon_api",
-         "mastodon_api_streaming",
-         "polls",
-         "pleroma_explicit_addressing",
-         "shareable_emoji_packs",
-         "multifetch",
-         "pleroma:api/v1/notifications:include_types_filter",
-         if Config.get([:media_proxy, :enabled]) do
-           "media_proxy"
-         end,
-         if Config.get([:gopher, :enabled]) do
-           "gopher"
-         end,
-         if Config.get([:chat, :enabled]) do
-           "chat"
-         end,
-         if Config.get([:instance, :allow_relay]) do
-           "relay"
-         end,
-         if Config.get([:instance, :safe_dm_mentions]) do
-           "safe_dm_mentions"
-         end,
-         "pleroma_emoji_reactions"
-       ]
-       |> Enum.filter(& &1)
+     features = InstanceView.features()
+     federation = InstanceView.federation()
  
      %{
        version: "2.0",
index a6cf28409f9609a7bf8dafd0e691f7322e180ee8,4fac5c100bbb2926e77515d4990bb9522a92f199..6e3e9905d019dc38d02dcf2b3faedf0f91c572dd
@@@ -1,1 -1,1 +1,5 @@@
- <!DOCTYPE html><html lang=en><head><meta charset=utf-8><meta name=viewport content="width=device-width,initial-scale=1,user-scalable=no"><link rel=stylesheet href=/static/font/css/fontello.css><link rel=stylesheet href=/static/font/css/animation.css><link rel=stylesheet href=/static/font/css/lato.css><title>Pleroma</title><!--server-generated-meta--><link rel=icon type=image/png href=/favicon.png><link rel=stylesheet href=/static/font/css/lato.css><link href=/static/css/vendors~app.b2603a50868c68a1c192.css rel=stylesheet><link href=/static/css/app.1055039ce3f2fe4dd110.css rel=stylesheet><link href=/static/fontello.1588196596336.css rel=stylesheet></head><body class=hidden><noscript>To use Pleroma, please enable JavaScript.</noscript><div id=app></div><script type=text/javascript src=/static/js/vendors~app.de343579e844e698d456.js></script><script type=text/javascript src=/static/js/app.e689136d879ca1c869c6.js></script></body></html>
 -<!DOCTYPE html><html lang=en><head><meta charset=utf-8><meta name=viewport content="width=device-width,initial-scale=1,user-scalable=no"><title>Pleroma</title><!--server-generated-meta--><link rel=icon type=image/png href=/favicon.png><link href=/static/css/vendors~app.18fea621d430000acc27.css rel=stylesheet><link href=/static/css/app.613cef07981cd95ccceb.css rel=stylesheet><link href=/static/fontello.1588419330867.css rel=stylesheet></head><body class=hidden><noscript>To use Pleroma, please enable JavaScript.</noscript><div id=app></div><script type=text/javascript src=/static/js/vendors~app.8aa781e6dd81307f544b.js></script><script type=text/javascript src=/static/js/app.fa89b90e606f4facd209.js></script></body></html>
++<<<<<<< HEAD
++<!DOCTYPE html><html lang=en><head><meta charset=utf-8><meta name=viewport content="width=device-width,initial-scale=1,user-scalable=no"><link rel=stylesheet href=/static/font/css/fontello.css><link rel=stylesheet href=/static/font/css/animation.css><link rel=stylesheet href=/static/font/css/lato.css><title>Pleroma</title><!--server-generated-meta--><link rel=icon type=image/png href=/favicon.png><link rel=stylesheet href=/static/font/css/lato.css><link href=/static/css/vendors~app.b2603a50868c68a1c192.css rel=stylesheet><link href=/static/css/app.1055039ce3f2fe4dd110.css rel=stylesheet><link href=/static/fontello.1588196596336.css rel=stylesheet></head><body class=hidden><noscript>To use Pleroma, please enable JavaScript.</noscript><div id=app></div><script type=text/javascript src=/static/js/vendors~app.de343579e844e698d456.js></script><script type=text/javascript src=/static/js/app.e689136d879ca1c869c6.js></script></body></html>
++=======
++<!DOCTYPE html><html lang=en><head><meta charset=utf-8><meta name=viewport content="width=device-width,initial-scale=1,user-scalable=no"><title>Pleroma</title><!--server-generated-meta--><link rel=icon type=image/png href=/favicon.png><link href=/static/css/vendors~app.18fea621d430000acc27.css rel=stylesheet><link href=/static/css/app.613cef07981cd95ccceb.css rel=stylesheet><link href=/static/fontello.1588419330867.css rel=stylesheet></head><body class=hidden><noscript>To use Pleroma, please enable JavaScript.</noscript><div id=app></div><script type=text/javascript src=/static/js/vendors~app.8aa781e6dd81307f544b.js></script><script type=text/javascript src=/static/js/app.fa89b90e606f4facd209.js></script></body></html>
++>>>>>>> fbcc53760e6fcd393513c05a5bd7a4a6a6f3b731
index 0e037d43de08b89be5b036dde50d7fa7ce6ab385,88244a5494891b78097b60f015749b8a45625001..ac065e10cf666f6acdfed04edcfb82b978f78a0b
@@@ -1,4 -1,4 +1,8 @@@
++<<<<<<< HEAD
 +var serviceWorkerOption = {"assets":["/static/fontello.1588196596336.css","/static/font/fontello.1588196596336.eot","/static/font/fontello.1588196596336.svg","/static/font/fontello.1588196596336.ttf","/static/font/fontello.1588196596336.woff","/static/font/fontello.1588196596336.woff2","/static/img/nsfw.ca95de9.png","/static/css/app.1055039ce3f2fe4dd110.css","/static/js/app.e689136d879ca1c869c6.js","/static/css/vendors~app.b2603a50868c68a1c192.css","/static/js/vendors~app.de343579e844e698d456.js","/static/js/2.f158cbd2b8770e467dfe.js"]};
++=======
+ var serviceWorkerOption = {"assets":["/static/fontello.1588419330867.css","/static/font/fontello.1588419330867.eot","/static/font/fontello.1588419330867.svg","/static/font/fontello.1588419330867.ttf","/static/font/fontello.1588419330867.woff","/static/font/fontello.1588419330867.woff2","/static/img/nsfw.74818f9.png","/static/css/app.613cef07981cd95ccceb.css","/static/js/app.fa89b90e606f4facd209.js","/static/css/vendors~app.18fea621d430000acc27.css","/static/js/vendors~app.8aa781e6dd81307f544b.js","/static/js/2.1c407059cd79fca99e19.js"]};
++>>>>>>> fbcc53760e6fcd393513c05a5bd7a4a6a6f3b731
          
          !function(e){var n={};function t(r){if(n[r])return n[r].exports;var o=n[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,t),o.l=!0,o.exports}t.m=e,t.c=n,t.d=function(e,n,r){t.o(e,n)||Object.defineProperty(e,n,{enumerable:!0,get:r})},t.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},t.t=function(e,n){if(1&n&&(e=t(e)),8&n)return e;if(4&n&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(t.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&n&&"string"!=typeof e)for(var o in e)t.d(r,o,function(n){return e[n]}.bind(null,o));return r},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},t.p="/",t(t.s=1)}([function(e,n){
  /*!