List should have validation
Reported by bahuvrihi | March 30th, 2009 @ 09:51 PM
Much like list_select.
def list(&validation); LIST; end
list_block = lambda do |input|
args = validate(input, [Array]).collect do |arg|
arg.kind_of?(String) ? YAML.load(arg) : arg
end
if validation
args.collect! {|arg| validation.call(arg) }
end
args
end
Comments and changes to this ticket
-
bahuvrihi May 3rd, 2009 @ 09:09 AM
- Assigned user set to bahuvrihi
- State changed from new to resolved
Please Sign in or create a free account to add a new ticket.
With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป
Class configurations that map to the command line.