We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
@filename
1 parent 8915627 commit b41d7c6Copy full SHA for b41d7c6
lib/logger/log_device.rb
@@ -79,8 +79,10 @@ def reopen(log = nil)
79
def set_dev(log)
80
if log.respond_to?(:write) and log.respond_to?(:close)
81
@dev = log
82
- if log.respond_to?(:path)
83
- @filename = log.path
+ if log.respond_to?(:path) and path = log.path
+ if File.exist?(path)
84
+ @filename = path
85
+ end
86
end
87
else
88
@dev = open_logfile(log)
0 commit comments