fixed serving data as JSON