String overflow caused by replace function.
The string returned by the replace() function is longer than 255 characters.
Check the length of the target string and the number of characters being added by the replace() function to be sure the total length of the resulting string is 255 characters or less.