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 RuboCop lint offenses #350

Merged
merged 1 commit into from
Jul 28, 2015
Merged

Conversation

agrimm
Copy link
Contributor

@agrimm agrimm commented Jul 26, 2015

Fix most of the offenses reported by RuboCop when run with the --lint option.

This was done so that when this gem is used while warnings are turned on (RUBYOPT="-w"), this gem produces fewer warnings.

The gem will still produce warnings about uninitialized instance variables being retrieved by monetizable.rb

@@ -14,7 +14,7 @@ end

APP_RAKEFILE = File.expand_path("../spec/dummy/Rakefile", __FILE__)

load 'rails/tasks/engine.rake' if File.exists?(APP_RAKEFILE)
load 'rails/tasks/engine.rake' if File.exist?(APP_RAKEFILE)
Copy link
Contributor

Choose a reason for hiding this comment

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

What's the reason for this change?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

File.exists? is deprecated - it generates a warning when Ruby is run in verbose mode from Ruby 2.1.0 onwards.

Copy link
Contributor

Choose a reason for hiding this comment

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

Oh, didn't know that

@antstorm
Copy link
Contributor

That looks good to go. Thanks, @agrimm!

antstorm added a commit that referenced this pull request Jul 28, 2015
@antstorm antstorm merged commit 6c5e6e2 into RubyMoney:master Jul 28, 2015
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.

2 participants