Fixed js json encode