A Thursday ruling said the Trump administration cannot eliminate the Building Resilient Infrastructure and Communities program without Congress.