Isn’t the argument in this function supposed to be str1 instead of str?
Yes I agree. I’ve reported the issue.