mirror of
https://github.com/OpenNebula/one.git
synced 2025-02-15 05:57:23 +03:00
parent
df4b534cf6
commit
595c1c9df7
@ -325,9 +325,15 @@ helpers do
|
||||
# @param params [Object] HTTP request parameters
|
||||
def update(object, params)
|
||||
attr = params[:data]
|
||||
type = params[:type].to_i
|
||||
type = params[:type]
|
||||
|
||||
type = 1 if type.nil?
|
||||
if type.nil?
|
||||
type = 1
|
||||
else
|
||||
type = type.to_i
|
||||
end
|
||||
|
||||
attr = request.body.read if attr.nil?
|
||||
|
||||
if type == 1
|
||||
error = "cannot be modified"
|
||||
|
Loading…
x
Reference in New Issue
Block a user