about summary refs log tree commit diff
path: root/app/presenters
diff options
context:
space:
mode:
authorAsh Furrow <ash@ashfurrow.com>2017-04-20 21:30:59 -0400
committerEugen <eugen@zeonfederated.com>2017-04-21 03:30:59 +0200
commita0ed88a99b736cc786b048126580a7e73c68b07e (patch)
treea1d53aa9f65a0cfe4717ca3f31819bb3c74bd490 /app/presenters
parent25d2853db2cb6603c398b6622526e579e974d593 (diff)
Adds version to about/more and API (#2181)
* Adds version.

* Cleans up code.

* Removes standalone endpoint and adds version to instance endpoint.

* Addresses feedback from #2181.
Diffstat (limited to 'app/presenters')
-rw-r--r--app/presenters/instance_presenter.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/app/presenters/instance_presenter.rb b/app/presenters/instance_presenter.rb
index 4188650d5..e583a38d0 100644
--- a/app/presenters/instance_presenter.rb
+++ b/app/presenters/instance_presenter.rb
@@ -25,4 +25,8 @@ class InstancePresenter
   def domain_count
     Rails.cache.fetch('distinct_domain_count') { Account.distinct.count(:domain) }
   end
+
+  def version_number
+    Mastodon::VERSION
+  end
 end