lib/picky/backend/file/text.rb in picky-3.0.0.pre1 vs lib/picky/backend/file/text.rb in picky-3.0.0.pre2
- old
+ new
@@ -34,21 +34,21 @@
# Yields an id string and a symbol token.
#
def retrieve
id = nil
token = nil
- ::File.open(cache_path, 'r:binary') do |file|
+ ::File.open(cache_path, 'r:utf-8') do |file|
file.each_line do |line|
id, token = line.split ?,, 2
yield id, (token.chomp! || token).to_sym
end
end
end
#
#
def open &block
- ::File.open cache_path, 'w:binary', &block
+ ::File.open cache_path, 'w:utf-8', &block
end
end
\ No newline at end of file