mirror of
https://github.com/OpenNebula/one.git
synced 2025-01-25 06:03:36 +03:00
feature #647: If the column does not exists using the -l option show an error
This commit is contained in:
parent
68a9e2ec27
commit
b083a9e458
@ -192,8 +192,7 @@ module CLIHelper
|
||||
size=@columns[field][:size]
|
||||
return "%#{minus}#{size}.#{size}s" % [ data.to_s ]
|
||||
else
|
||||
puts "Column not defined"
|
||||
exit -1
|
||||
exit -1, "Column not defined"
|
||||
end
|
||||
end
|
||||
|
||||
|
@ -169,13 +169,7 @@ EOT
|
||||
if comm
|
||||
check_args!(comm_name, comm[:arity], comm[:args_format])
|
||||
|
||||
begin
|
||||
rc = comm[:proc].call
|
||||
rescue Exception =>e
|
||||
puts e.message
|
||||
exit -1
|
||||
end
|
||||
|
||||
rc = comm[:proc].call
|
||||
if rc.instance_of?(Array)
|
||||
puts rc[1]
|
||||
exit rc.first
|
||||
|
Loading…
x
Reference in New Issue
Block a user