fixed bug with uri encoding