sample config: document how to make CSPPlug send STS headers (off by default to allow...
[akkoma] / lib / mix / tasks / make_moderator.ex
index 4d427cfd8f40543c5380697bb80b374912d865d3..15586dc307beaa21cb6072d756f415dc5332f1a0 100644 (file)
@@ -1,11 +1,18 @@
 defmodule Mix.Tasks.SetModerator do
+  @moduledoc """
+  Set moderator to a local user
+
+  Usage: ``mix set_moderator <nickname>``
+
+  Example: ``mix set_moderator lain``
+  """
+
   use Mix.Task
   import Mix.Ecto
   alias Pleroma.{Repo, User}
 
-  @shortdoc "Set moderator status"
   def run([nickname | rest]) do
-    ensure_started(Repo, [])
+    Application.ensure_all_started(:pleroma)
 
     moderator =
       case rest do