Fix js to interpret domain