2019-03-22 10:53:38 +01:00
|
|
|
defmodule MobilizonWeb.Resolvers.Config do
|
|
|
|
@moduledoc """
|
|
|
|
Handles the config-related GraphQL calls
|
|
|
|
"""
|
2019-03-22 13:58:19 +01:00
|
|
|
|
2019-03-22 10:53:38 +01:00
|
|
|
import Mobilizon.CommonConfig
|
|
|
|
|
|
|
|
@doc """
|
|
|
|
Get config
|
|
|
|
"""
|
|
|
|
def get_config(_parent, _params, _context) do
|
|
|
|
{:ok, %{name: instance_name(), registrations_open: registrations_open?()}}
|
|
|
|
end
|
|
|
|
end
|