On Thursday 17 July 2008 19:15:52 James Keenan via RT wrote: > + if (! defined $args->{revision}) { > + $args->{revision} = 'unknown'; > + _print_to_cache($args->{cache}, $args->{revision}); > + return $args->{revision}; > + } else { > + if (defined ($args->{prev}) && ($args->{revision} ne > $args->{prev})) { + _print_to_cache($args->{cache}, > $args->{revision}); > + return $args->{revision}; > + } > + else { > + return $args->{current}; > + } > } > }
I would find this clearer if you reversed the top level conditions. In English, this reads: if the revision isn't defined, then do this otherwise do that Flipping the order changes it to: if the revision is defined, do this otherwise, do that There's no double-negative. -- c