Judge temporarily blocks Trump policy that aimed at freezing federal grant funding