Fix backwards compatibility code to handle an old style public
attribute correctly. Closes #2242.
This commit is contained in:
parent
ade96da19f
commit
543e8c5503
1 changed files with 8 additions and 4 deletions
|
@ -293,10 +293,14 @@ class TraceController < ApplicationController
|
|||
if request.post?
|
||||
tags = params[:tags] || ""
|
||||
description = params[:description] || ""
|
||||
visibility = params[:visibility] || false
|
||||
visibility = params[:visibility]
|
||||
|
||||
if params[:public] && !visibility
|
||||
visibility = "public"
|
||||
if visibility.nil?
|
||||
if params[:public]
|
||||
visibility = "public"
|
||||
else
|
||||
visibility = "private"
|
||||
end
|
||||
end
|
||||
|
||||
if params[:file].respond_to?(:read)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue