The law would work differently if they, as designated interpreters of the law, interpreted the law differently. If they said you can’t have infinite dark money running campaigns because that violates the rights of poor voters, then things would be very different. Plenty of SCOTUS cases have made significant changes to how the law is interpreted and enforced. Congress also seems to very rarely pass laws to counter SCOTUS decisions. So yeah, if we had fewer federalists and conservatives on SCOTUS and more progressives, I think it would have been decided differently, as well as other significant cases.