mirror of
https://github.com/Shopify/liquid.git
synced 2026-09-16 01:10:41 -07:00
start_index will never be -1
This commit is contained in:
@@ -300,7 +300,7 @@ module Liquid
|
||||
def replace_last(input, string, replacement)
|
||||
start_index = input.to_s.rindex(string.to_s)
|
||||
|
||||
if !start_index.nil? && start_index > -1
|
||||
if !start_index.nil?
|
||||
end_index = start_index + replacement.to_s.length
|
||||
|
||||
duplicate = input.to_s.dup
|
||||
|
||||
Reference in New Issue
Block a user