Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Style/RescueModifier offenses #760

Closed

Conversation

magni-
Copy link
Contributor

@magni- magni- commented Apr 4, 2016

From #752.

@@ -218,7 +218,7 @@ def changeset

# Returns who put the item into the state stored in this version.
def paper_trail_originator
@paper_trail_originator ||= previous.whodunnit rescue nil
@paper_trail_originator ||= previous && previous.whodunnit
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd rather use try here. PT still depends on activesupport >= 3, so we can't use try!.

@jaredbeck
Copy link
Member

I'd rather use try here.

This is the only necessary change. The rest looks good!

@batter
Copy link
Collaborator

batter commented Apr 4, 2016

👍

@jaredbeck
Copy link
Member

Closed by #762

Thanks Paul!

@jaredbeck jaredbeck closed this Apr 5, 2016
@magni- magni- deleted the rubocop_rescue_modifier branch April 5, 2016 01:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants