Skip to content

Commit

Permalink
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions core/src/main/java/org/jruby/RubyString.java
Original file line number Diff line number Diff line change
@@ -3000,12 +3000,10 @@ private IRubyObject subpat19(Ruby runtime, ThreadContext context, RubyRegexp reg
}

private IRubyObject subpat19(Ruby runtime, ThreadContext context, RubyRegexp regex) {
IRubyObject[] holder = {context.nil};

int result = regex.search19(context, this, 0, false);

if (result >= 0) {
return RubyRegexp.nth_match(0, holder[0]);
return RubyRegexp.nth_match(0, context.getBackRef());
}

return runtime.getNil();

0 comments on commit dd733e4

Please sign in to comment.