FIX: Check backtrace and backtrace_locations before trying to print an error
... during plugin initialization.
This commit is contained in:
parent
f038f8f154
commit
38c05a4f07
|
@ -6,7 +6,7 @@ def plugin_initialization_guard(&block)
|
|||
rescue => error
|
||||
plugins_directory = Rails.root + 'plugins'
|
||||
|
||||
if error.backtrace
|
||||
if error.backtrace && error.backtrace_locations
|
||||
plugin_path = error.backtrace_locations.lazy.map do |location|
|
||||
Pathname.new(location.absolute_path)
|
||||
.ascend
|
||||
|
|
Loading…
Reference in New Issue