diff options
author | Jonne Haß <me@jhass.eu> | 2014-10-14 15:25:16 +0400 |
---|---|---|
committer | Jonne Haß <me@jhass.eu> | 2014-10-14 15:25:16 +0400 |
commit | a7c702d6312150f5774b6ec8863cec23404f769f (patch) | |
tree | 0439ee90263a13eb5be1c7742dbfbf4441cc64b7 | |
parent | 0a20d6a2b70eb55d5bea58c718bef75d6814b42c (diff) | |
parent | adc839d6202046fbea32bb91507378a74daf6c00 (diff) |
Merge pull request #5308 from Flaburgan/add-network-key-to-statistics
Add network key to statistics.json
Conflicts:
Changelog.md
-rw-r--r-- | Changelog.md | 1 | ||||
-rw-r--r-- | app/presenters/statistics_presenter.rb | 1 | ||||
-rw-r--r-- | spec/presenters/statistics_presenter_spec.rb | 2 |
3 files changed, 4 insertions, 0 deletions
diff --git a/Changelog.md b/Changelog.md index f14718b1e..65e766325 100644 --- a/Changelog.md +++ b/Changelog.md @@ -80,6 +80,7 @@ The keys will still be available in the root level within the 0.5 release. The o * Display visibility icon in publisher aspects dropdown [#4982](https://github.com/diaspora/diaspora/pull/4982) * Add a link to the reported comment in the admin panel [#5337](https://github.com/diaspora/diaspora/pull/5337) * Strip search query from leading and trailing whitespace [#5317](https://github.com/diaspora/diaspora/pull/5317) +* Add the "network" key to statistics.json and set it to "Diaspora" [#5308](https://github.com/diaspora/diaspora/pull/5308) # 0.4.1.1 diff --git a/app/presenters/statistics_presenter.rb b/app/presenters/statistics_presenter.rb index f723fc639..5f8459a8b 100644 --- a/app/presenters/statistics_presenter.rb +++ b/app/presenters/statistics_presenter.rb @@ -3,6 +3,7 @@ class StatisticsPresenter def as_json(options={}) result = { 'name' => AppConfig.settings.pod_name, + 'network' => "Diaspora", 'version' => AppConfig.version_string, 'registrations_open' => AppConfig.settings.enable_registrations, 'services' => [] diff --git a/spec/presenters/statistics_presenter_spec.rb b/spec/presenters/statistics_presenter_spec.rb index ebd6e2ff7..22a1233f1 100644 --- a/spec/presenters/statistics_presenter_spec.rb +++ b/spec/presenters/statistics_presenter_spec.rb @@ -22,6 +22,7 @@ describe StatisticsPresenter do it 'provides generic pod data in json' do expect(@presenter.as_json).to eq({ "name" => AppConfig.settings.pod_name, + "network" => "Diaspora", "version" => AppConfig.version_string, "registrations_open" => AppConfig.settings.enable_registrations, "services"=> ["facebook",], @@ -48,6 +49,7 @@ describe StatisticsPresenter do it 'provides generic pod data and counts in json' do expect(@presenter.as_json).to eq({ "name" => AppConfig.settings.pod_name, + "network" => "Diaspora", "version" => AppConfig.version_string, "registrations_open" => AppConfig.settings.enable_registrations, "total_users" => User.count, |