Skip to content
This repository has been archived by the owner on Jul 27, 2023. It is now read-only.

Commit

Permalink
Merge pull request #32 from bbonamin/ruby-2.0-compatibility
Browse files Browse the repository at this point in the history
Add compatibility with Ruby 2.0
  • Loading branch information
jonkessler authored May 7, 2017
2 parents 8513869 + fcdc0b3 commit 0b616e0
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 2 additions & 0 deletions eslint-rails.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ Gem::Specification.new do |spec|
spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
spec.require_paths = ['lib']

spec.required_ruby_version = '>= 2.0.0'

spec.add_dependency 'railties', '>= 3.2'
spec.add_dependency 'execjs'
spec.add_dependency 'colorize'
Expand Down
4 changes: 3 additions & 1 deletion lib/eslint-rails/config.rb
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,9 @@ def self.read(force_default: false)
CONFIG_PATH = 'config/eslint.json'
private_constant :CONFIG_PATH

def initialize(force_default:)
def initialize(force_default: nil)
raise(ArgumentError, 'force_default is required') if force_default.nil?

@force_default = force_default
@custom_file = Rails.root.join(CONFIG_PATH)
@default_file = ESLintRails::Engine.root.join(CONFIG_PATH)
Expand Down

0 comments on commit 0b616e0

Please sign in to comment.