rubocop style updates

r509 has some inconsistencies and various style issues that will be helped by complying with (parts) of rubocop's style linting. This PR represents that work.