mirror of
https://github.com/puppetlabs/vmpooler.git
synced 2026-01-26 18:08:42 -05:00
Use boolean instead of string for 'ok' response
This commit is contained in:
parent
e051e625c8
commit
6c74a89e11
1 changed files with 3 additions and 3 deletions
|
|
@ -67,10 +67,10 @@ post '/vm/:template' do
|
||||||
|
|
||||||
logger.log('s', "[<] '#{vm}' moved to 'running' queue")
|
logger.log('s', "[<] '#{vm}' moved to 'running' queue")
|
||||||
|
|
||||||
result[params[:template]]['ok'] = 'true'
|
result[params[:template]]['ok'] = true
|
||||||
result[params[:template]]['hostname'] = vm
|
result[params[:template]]['hostname'] = vm
|
||||||
else
|
else
|
||||||
result[params[:template]]['ok'] = 'false'
|
result[params[:template]]['ok'] = false
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
@ -89,7 +89,7 @@ delete '/vm/:hostname' do
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
result['ok'] = 'true'
|
result['ok'] = true
|
||||||
JSON.pretty_generate(result)
|
JSON.pretty_generate(result)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue