From: 7stud -- Date: 2008-02-17T10:29:41+09:00 Subject: Re: where to check for nils or empty? John Honovich wrote: > I am processing arrays of URLs. I call a series of methods to delete or > modify those urls. I have a risk that those methods will return an empty > or null array. > > My approach works currently but feels ugly and repetitive. > > Any advice for improving this? > Some counter advice: inject() is the definition of slow and ugly. You should reject any code that uses inject() out of hand. -- Posted via http://www.ruby-forum.com/.