TRENTON, N.J. (AP) — A New Jersey court has denied an appeal from a high school that lost a state basketball tournament game when referees wrongly overturned a buzzer-beating basket.

The state appellate division ruled late Friday that it would not grant Manasquan school officials' petition stemming from this week's loss to Camden.

“Judges should generally ‘refrain from interfering with the internal matters of sports associations,’” the court said, citing a legal precedent. It added that courts generally “do not sit as referees of football any more than (they) sit as the ‘umpires’ of baseball or the ‘super-scorer(s)’ for stock car racing.”

The decision likely means that a state title game set for Saturday between Camden and Newark can go forward.

Manasquan initially was declared the winner over Camden in Tuesday night’s Group 2 semifinal game. However, the call was overturned when the referees discussed the shot and concluded it came after the buzzer, giving Camden a 46-45 win.

A review of multiple videos of the final seconds clearly showed the shot was in the air and was going into the basket when the final buzzer sounded, meaning it should have counted. The controversy quickly became a topic of conversation on national news programs and sports radio and television shows.

The New Jersey State Interscholastic Athletic Association (NJSIAA), which oversees scholastic sports, acknowledged Wednesday that the referees made the wrong call but said it would not overturn Camden’s victory.

In a statement, the agency said it understands Manasquan’s frustration but “the rules are clear — once game officials leave the ‘visual confines of the playing court,’ the game is concluded, and the score is official.” The agency does not use instant replay.

Manasquan school officials had asked acting education commissioner Kevin Dehmer to delay the state game while it appealed in court, arguing that it should be in the final. But Dehmer ruled Friday that Manasquan's claims were “not reviewable,” citing the guidelines of the NJSIAA.

Manasquan filed an appeal in New Jersey state appellate court. An order signed by Judge Joseph Marcyzk denied the school's petition to consider the matter.

Manasquan Schools Superintendent Frank Kaysan called the appeal “really the last step in this process. We could go to the New Jersey Supreme Court, but we're not going to do that.”

Manasquan had earlier asked a state superior court judge to put the upcoming state title game on hold. The judge denied the motion Thursday, ruling the court does not have jurisdiction to stop the game until the state education department and a state appellate court weigh in on the matter.

School district attorney Michael Gross said Thursday that “the district and the students in the district are deserved of getting the right outcome to this incident. So we are taking all these necessary steps to try to right the wrong that was done.”

Lou Cappelli Jr., an attorney representing the Camden school district, painted Manasquan's legal battle as sour grapes and a waste of taxpayer money and the court's time.

“Are we going to go back and look at all 32 minutes of the game and come to the judge and say ‘judge, this wasn’t a foul.’ It’s ridiculous,” Cappelli told the Asbury Park Press.

Kaysan, though, called the matter “a learning situation, a learning environment” for students.

“We want to teach the students at Manasquan that there is a process and procedure when you are on the right side of something to obtain equity, and what we did here is use the process and the procedure the State of New Jersey put into effect — everyone knows we won the game, but we want to do so using the avenue the state has given us to do it properly," Kaysan said.

The Newark school district said Thursday that it would not oppose efforts to delay the title game if that allowed a court to issue a “correct, full and fair decision.”

It also said that if the call overturning Manasquan's basket was found to be incorrect, the court should “overturn that decision in the interest of justice and in the interest of teaching our students a valuable lesson. ... All of the teams who competed this season deserve to know that adults who make mistakes can have them corrected.”