Add method to update content of note.

This commit is contained in:
hassaku 2015-01-07 13:56:22 +09:00
parent 5c3e8952bc
commit e2e884e317

View File

@ -12,6 +12,18 @@ class Fluentd
def initialize(file_path)
@file_path = file_path
end
def update(content)
begin
File.open(@file_path, "w") do |f|
f.write content
end
rescue => ex
Rails.logger.error ex.message
return false
end
true
end
end
end
end