diff options
author | Maksim Pechnikov <parallel588@gmail.com> | 2020-03-08 14:23:41 +0300 |
---|---|---|
committer | Maksim Pechnikov <parallel588@gmail.com> | 2020-03-08 14:23:59 +0300 |
commit | a85194e94d86f18bb3dc72e54861c6c2112f7b84 (patch) | |
tree | 64507d256c8dce1a4f30221377b925ad4f4a8a94 /lib/pleroma/stats.ex | |
parent | 252a65dc18d4bf5c53ffff5eadb878e9d063c520 (diff) | |
parent | 6d797b99282ff1067c6af04b3e1775ff2281333b (diff) | |
download | pleroma-issue/1469.tar.gz |
Merge branch 'develop' into issue/1469issue/1469
Diffstat (limited to 'lib/pleroma/stats.ex')
-rw-r--r-- | lib/pleroma/stats.ex | 17 |
1 files changed, 4 insertions, 13 deletions
diff --git a/lib/pleroma/stats.ex b/lib/pleroma/stats.ex index 771a06e32..4446562ac 100644 --- a/lib/pleroma/stats.ex +++ b/lib/pleroma/stats.ex @@ -1,5 +1,5 @@ # Pleroma: A lightweight social networking server -# Copyright © 2017-2019 Pleroma Authors <https://pleroma.social/> +# Copyright © 2017-2020 Pleroma Authors <https://pleroma.social/> # SPDX-License-Identifier: AGPL-3.0-only defmodule Pleroma.Stats do @@ -10,19 +10,10 @@ defmodule Pleroma.Stats do use GenServer - @init_state %{ - peers: [], - stats: %{ - domain_count: 0, - status_count: 0, - user_count: 0 - } - } - def start_link(_) do GenServer.start_link( __MODULE__, - @init_state, + nil, name: __MODULE__ ) end @@ -53,8 +44,8 @@ defmodule Pleroma.Stats do peers end - def init(args) do - {:ok, args} + def init(_args) do + {:ok, get_stat_data()} end def handle_call(:force_update, _from, _state) do |