debian-mirror-gitlab/app/controllers/projects/usage_ping_controller.rb

14 lines
356 B
Ruby
Raw Normal View History

2019-12-26 22:10:19 +05:30
# frozen_string_literal: true
class Projects::UsagePingController < Projects::ApplicationController
before_action :authenticate_user!
def web_ide_clientside_preview
return render_404 unless Gitlab::CurrentSettings.web_ide_clientside_preview_enabled?
Gitlab::UsageDataCounters::WebIdeCounter.increment_previews_count
head(200)
end
end