According to MLK the difference between a just law and an unjust law is that a Just law is a manmade code that squares away with the moral law or law of God. It is a law that uplifts human personality. An unjust law is a code that is out of harmony with the moral law. It is any law that degrades human personality. If its morally right, it’s just if it goes against morals its unjust.
I do believe that it is important to be able to distinguish what is considered a just or unjust law. Knowing what is morally correct helps us determine wrong from right. It can affect our politics because it helps us when having to make certain decisions when it comes to us having to vote these distinctions help us see which laws or candidates have their head and hearts in the right place.
An example of a just law could be same sex marriage because it is morally correct to let people marry their loved ones despite what they identify as. Having to have an ID in order to vote is a bit unlawful because there are a lot of minority voters who are less likely to have certain paperwork in order to receive an ID. Not to mention in order to get an ID it costs money some people would have to choose between maybe eating that day or getting an ID.