Ruby 1.9 support
Ruby style improvements for consistency