Removes the useless "after" in the replacement regexp.