switch to ruby 1.9+ lambda syntax
tidying up