Utf-8 encoding problem fixed when encoding data to json