Skip to content
Snippets Groups Projects
Commit bb5f0671 authored by Lin Jen-Shin's avatar Lin Jen-Shin
Browse files

Rename to ref_name so it's aligning with API

parent 33368281
Branches
Tags
1 merge request!5142Add a download buttons for Build Artifacts
Pipeline #
Loading
Loading
@@ -60,8 +60,8 @@ class Projects::ArtifactsController < Projects::ApplicationController
end
 
def build_from_ref
if params[:ref]
builds = project.builds_for(params[:build_name], params[:ref])
if params[:ref_name]
builds = project.builds_for(params[:build_name], params[:ref_name])
 
builds.success.latest.first
end
Loading
Loading
Loading
Loading
@@ -735,8 +735,8 @@ Rails.application.routes.draw do
 
resources :artifacts, only: [] do
collection do
get :search, path: ':ref/:build_name/*path', format: false,
constraints: { ref: /.+/ } # ref could have /
get :search, path: ':ref_name/:build_name/*path', format: false,
constraints: { ref_name: /.+/ } # ref could have /
end
end
 
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment