app/controllers/application_controller.rb in fluentd-ui-0.1.0 vs app/controllers/application_controller.rb in fluentd-ui-0.1.1

- old
+ new

@@ -99,12 +99,12 @@ end I18n.locale = prefer end def file_tail(path, limit = 10) - return unless path - return unless File.exists? path + return [] unless path + return [] unless File.exists? path reader = FileReverseReader.new(File.open(path)) - return if reader.binary_file? + return [] if reader.binary_file? reader.tail(limit) end end