fixing string encode