2018-09-25 23:45:43 -04:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2018-03-19 12:11:12 -04:00
|
|
|
class Projects::DeployTokensController < Projects::ApplicationController
|
|
|
|
before_action :authorize_admin_project!
|
|
|
|
|
|
|
|
def revoke
|
|
|
|
@token = @project.deploy_tokens.find(params[:id])
|
|
|
|
@token.revoke!
|
|
|
|
|
2018-08-08 02:17:43 -04:00
|
|
|
redirect_to project_settings_repository_path(project, anchor: 'js-deploy-tokens')
|
2018-03-19 12:11:12 -04:00
|
|
|
end
|
|
|
|
end
|