Minor bug fix regarding str_ functions