forked from rails/rails
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ErrorHighlight 0.5.1+ is always available since Ruby 3.2
This commit removes conditions to see if ErrorHighligh 0.4.0 or higher version is available since ErrorHighlight 0.5.1+ is always available since Ruby 3.2 that is required by the Rails current main branch. - Ruby 3.2.0 Released https://www.ruby-lang.org/en/news/2022/12/25/ruby-3-2-0-released/ ErrorHighlight.spot(ex, backtrace_location: self) > The following default gems are updated. > error_highlight 0.5.1 Related to rails#48299 rails#53041
- Loading branch information
Showing
5 changed files
with
16 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
9 changes: 2 additions & 7 deletions
9
activesupport/lib/active_support/core_ext/thread/backtrace/location.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,7 @@ | ||
# frozen_string_literal: true | ||
|
||
class Thread::Backtrace::Location # :nodoc: | ||
if defined?(ErrorHighlight) && Gem::Version.new(ErrorHighlight::VERSION) >= Gem::Version.new("0.4.0") | ||
def spot(ex) | ||
ErrorHighlight.spot(ex, backtrace_location: self) | ||
end | ||
else | ||
def spot(ex) | ||
end | ||
def spot(ex) | ||
ErrorHighlight.spot(ex, backtrace_location: self) | ||
end | ||
end |