Refactoring Api::Geo#check_node_restricted_project_ids!

parent 18ab996f
......@@ -114,9 +114,8 @@ module API
def check_node_restricted_project_ids!
return unless params.key?(:project_id)
return if Gitlab::Geo.current_node&.restricted_project_ids.nil?
unless Gitlab::Geo.current_node.restricted_project_ids.include?(params[:project_id].to_i)
unless Gitlab::Geo.current_node&.projects_include?(params[:project_id].to_i)
not_found!
end
end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment