correcting stupid Ruby errors