Class: LoggerJson::Writter

Inherits:
Object
  • Object
show all
Defined in:
lib/logger_json/writter.rb

Class Method Summary collapse

Class Method Details

.logger_json(path, json) ⇒ Object



3
4
5
6
# File 'lib/logger_json/writter.rb', line 3

def self.logger_json(path, json)
  return puts json if path.nil?
  open(path, 'a') { |f| f.puts json}
end