A federal judge has refused to throw out a federal gun case against Hunter Biden, rejecting the president’s son’s claim that he is being prosecuted for political purposes as well as other arguments.

US District Judge Maryellen Noreika denied defence efforts to scuttle the prosecution charging Biden with lying about his drug use in October 2018 on a form to buy a gun that he kept for about 11 days.

His lawyers had argued the case was politically motivated and asserted that an immunity provision from an original plea deal that fell apart still holds. They had also challenged the appointment of special counsel David Weiss, the US attorney in Delaware, to lead the prosecution.

The judge has not yet ruled on a challenge to the constitutionality of the gun charges.

Biden faces separate tax counts in Los Angeles alleging he failed to pay at least 1.4 million dollars in taxes over three years while living an “extravagant lifestyle,” during his days of using drugs. The judge overseeing that case refused to dismiss the charges earlier this month.

He has pleaded not guilty in both cases. A representative for his legal team did not respond to a request for a comment on Friday.

The president’s son has acknowledged struggling with an addiction to crack cocaine during that period in 2018, but his lawyers have said he did not break the law and another nonviolent, first-time offender would not have been charged.