Small Business Administration Blocked From Giving Race-Based Grants

A federal judge in Texas sided with a café owner who is suing the Small Business Association for prioritizing relief money based on race and gender. But in what situations can these race-based considerations stay in line with the Constitution?