new ref switch
This commit is contained in:
parent
5f900772c2
commit
3ba392b3cb
9 changed files with 1314 additions and 50 deletions
|
@ -57,19 +57,13 @@ class ApplicationController < ActionController::Base
|
|||
end
|
||||
|
||||
def load_refs
|
||||
@branch = unless params[:branch].blank?
|
||||
params[:branch]
|
||||
else
|
||||
nil
|
||||
end
|
||||
|
||||
@tag = unless params[:tag].blank?
|
||||
params[:tag]
|
||||
else
|
||||
nil
|
||||
end
|
||||
|
||||
@ref = @branch || @tag || "master"
|
||||
unless params[:ref].blank?
|
||||
@ref = params[:ref]
|
||||
else
|
||||
@branch = params[:branch].blank? ? nil : params[:branch]
|
||||
@tag = params[:tag].blank? ? nil : params[:tag]
|
||||
@ref = @branch || @tag || "master"
|
||||
end
|
||||
end
|
||||
|
||||
def render_404
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue