Skip to content

Commit

Permalink
fix: compatibility with Crystal 0.26
Browse files Browse the repository at this point in the history
BREAKING CHANGE: `File.each_line(path)` is no longer valid in Crystal since 0.26.

See crystal-lang/crystal#6301
  • Loading branch information
vladfaust committed Aug 14, 2018
1 parent 0939e6d commit 8c98c53
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/migrate/migration.cr
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,9 @@ module Migrate
end

def initialize(file_path : String)
initialize(File.each_line(file_path))
File.open(file_path) do |file|
initialize(file.each_line)
end
end

def initialize(file : File)
Expand Down

0 comments on commit 8c98c53

Please sign in to comment.