Adding utf8 encode to correct output issues