Skip to content

Commit

Permalink
fixed chr grabbing for older rb implementations
Browse files Browse the repository at this point in the history
  • Loading branch information
alexcoplan committed Jul 17, 2012
1 parent 477fac1 commit 83cdba4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/rspec/expectations/differ.rb
Original file line number Diff line number Diff line change
Expand Up @@ -75,13 +75,13 @@ def color_diff(diff)
blue = 34

lines = diff.lines.map do |line|
case line[0]
case line[0].chr
when "+"
color(line, green)
when "-"
color(line, red)
when "@"
line[1] == "@" ? color(line, blue) : line
line[1].chr == "@" ? color(line, blue) : line
else
line
end
Expand Down

0 comments on commit 83cdba4

Please sign in to comment.