Skip to content
代码片段 群组 项目
未验证 提交 554284bd 编辑于 作者: Carla Drago's avatar Carla Drago 提交者: GitLab
浏览文件

Release jira_connect_proxy_create_branch

This removes the :jira_connect_proxy_create_branch feature flag as the feature has been globally enabled on production for a week with no issues.

Changelog: fixed
上级 14082ebf
No related branches found
No related tags found
加载中
# frozen_string_literal: true # frozen_string_literal: true
class JiraConnect::BranchesController < JiraConnect::ApplicationController class JiraConnect::BranchesController < JiraConnect::ApplicationController
# before_action :authenticate_user!, only: :new before_action :authenticate_user!, only: :new
skip_before_action :verify_atlassian_jwt!, only: :new skip_before_action :verify_atlassian_jwt!, only: :new
def new def new
# move authenticate_user! to a before_action when we remove the jira_connect_proxy_create_branch feature flag
authenticate_user! if Feature.enabled?(:jira_connect_proxy_create_branch, current_user)
@new_branch_data = new_branch_data @new_branch_data = new_branch_data
end end
# If the GitLab for Jira Cloud app was installed from the Jira marketplace and points to a self-managed instance, # If the GitLab for Jira Cloud app was installed from the Jira marketplace and points to a self-managed instance,
# we route the user to the self-managed instance, otherwise we redirect to :new # we route the user to the self-managed instance, otherwise we redirect to :new
def route def route
if Feature.enabled?(:jira_connect_proxy_create_branch, current_user) && current_jira_installation.proxy? if current_jira_installation.proxy?
redirect_to "#{current_jira_installation.create_branch_url}?#{request.query_string}" redirect_to "#{current_jira_installation.create_branch_url}?#{request.query_string}"
return return
......
---
name: jira_connect_proxy_create_branch
feature_issue_url: https://gitlab.com/gitlab-org/gitlab/-/issues/391432
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/149377
rollout_issue_url: https://gitlab.com/gitlab-org/gitlab/-/issues/466462
milestone: '17.2'
group: group::import and integrate
type: gitlab_com_derisk
default_enabled: false
...@@ -89,17 +89,6 @@ ...@@ -89,17 +89,6 @@
expect(response).to redirect_to("#{create_branch_url}?#{query_string}") expect(response).to redirect_to("#{create_branch_url}?#{query_string}")
end end
end end
context 'when jira_connect_proxy_create_branch feature is disabled' do
before do
stub_feature_flags(jira_connect_proxy_create_branch: false)
end
it 'redirects to :new' do
get :route, params: params
expect(response).to redirect_to("#{new_jira_connect_branch_url}?#{query_string}")
end
end
end end
end end
end end
0% 加载中 .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册