Skip to content

Commit

Permalink
Just use File.readlines
Browse files Browse the repository at this point in the history
  • Loading branch information
nobu committed Jun 1, 2019
1 parent b487b39 commit 3034d66
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions lib/reline/config.rb
Expand Up @@ -80,9 +80,7 @@ def read(file = DEFAULT_PATH)
if file.respond_to?(:readlines)
lines = file.readlines
else
File.open(file, 'rt') do |f|
lines = f.readlines
end
lines = File.readlines(file)
end
rescue Errno::ENOENT
return nil
Expand Down

0 comments on commit 3034d66

Please sign in to comment.