The furor over the family separation issue – children not being kept with their parents who have been detained for illegally entering the country – is odd. This is not some new phenomenon suddenly imposed by the Trump administration. It happened during the Obama, Bush, and Clinton administrations, too.

Where did the policy come from? In 1997, then-Attorney General Janet Reno settled a lawsuit, Flores v. Reno, filed in California challenging the Clinton administration’s detention of juvenile migrants taken into custody by the INS. In the settlement, the government agreed that it could detain unaccompanied minors for only 20 days before releasing them to the Department of Health and Human Services for placement either in foster care or with their parents, close relatives, or a legal guardian. A controversial decision by the U.S. Court of Appeals for the Ninth Circuit extended this 20-day limit to juveniles who illegally cross the border with their parents.

So the reason that children can’t stay with their parents who are being prosecuted under federal immigration law is because of a court’s misinterpretation of a settlement agreed to by the Clinton administration – not the Trump administration.

Keep in mind that those parents would be instantly reunited with their families if they did the right thing – volunteered to return to their native country. By breaking the law and bypassing our legal immigration process, those parents are responsible for what is happening to their children.

President Trump signed an executive order on June 20 directing that families who enter the country illegally be kept together “to the extent permitted by law.” This is an obvious reference to the Flores settlement and the limits it places on the government. But at least Trump is trying to do something about that. The executive order directs the attorney general to go to the California court with jurisdiction over the Flores case and ask the court to modify the settlement agreement to allow the government to keep families together while the parents are detained.

The current outrage over this was generated by a recent Associated Press story about 2,000 children separated from their parents. The hypocrisy of the critics and protesters is demonstrated by their lack of concern for the much larger number of children who are placed in foster care when their parents are incarcerated. We don’t fail to arrest, prosecute and jail Americans who commit crimes because they have children.

In 2016 alone, according to a report by the U.S. Department of Health and Human Services, 20,939 children were placed in foster care because their parents were incarcerated. In 2015, the number was 21,006. So the number of American kids who are placed in foster care because their parents are incarcerated is exponentially larger than the number of children who are also separated from the parents because their parents broke federal immigration law.

Another reason for the separation problem is immigrants who enter the county illegally making false asylum claims to avoid being deported. If an immigrant follows the law by presenting himself at a port of entry with his family and claiming asylum, then his family will stay together. It is when immigrants who are caught illegally crossing the border then claim asylum that they risk being prosecuted for illegal entry. They are then separated from their children because of the Clinton-era settlement.

Many immigrants claiming asylum pass through countries such as Mexico with their own generous asylum laws. If an immigrant doesn’t claim asylum before he gets to the U.S., that is a clear indication that he is coming here for economic reasons, not because he has a valid asylum claim.

No one wants to see families separated – and that includes the families of immigrants and of American citizens. But one of the consequences of breaking the law is that you may be separated from your children when you go to prison. Moreover, they may end up in foster care because of your misdeeds. That applies whether you are committing a domestic crime such as assault or robbery, or violating federal immigration law by illegally crossing – or recrossing – our border.

Hans A. von Spakovsky is a senior legal fellow at The Heritage Foundation. He is the co-author of “Who’s Counting? How Fraudsters and Bureaucrats Put Your Vote at Risk” and “Obama’s Enforcer: Eric Holder’s Justice Department.”