On Mar 18, 4:59 pm, Frederick Cheung <[email protected]>
wrote:

> Because @monkey is a hash what gets yielded to you is an array, the
> first element is the key (ie '133' or '145') and the second is the
> value, whereas your code seems to assume that x is a hash.

Sorry for being so dense, but why does

@monkey.delete_if{ |k,v| v[ "value" ] == '' }

Throw the same error?  Any idea what the proper syntax would be to
delete the element for which value is blank?

TIA,
Craig

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to