Judge rules county doesn't have to pay