1
0
mirror of https://github.com/LaCasemate/fab-manager.git synced 2024-12-01 12:24:28 +01:00
fab-manager/app/controllers/api/version_controller.rb
2019-01-07 12:48:22 +01:00

11 lines
267 B
Ruby

class API::VersionController < API::ApiController
before_action :authenticate_user!
def show
authorize :version
package = File.read('package.json')
version = JSON.parse(package)['version']
render json: { version: version }, status: :ok
end
end