TRENTON, N.J. (AP) — A New Jersey appeals court has ruled that law enforcement agencies can view private messages and tweets from private accounts on Twitter if they get a warrant.

The three-judge panel on Thursday ruled in favor of Essex County prosecutors who attempted to access video posts from two Twitter profiles.

The case turned on what type of warrant is needed: a communications data warrant or a wiretapping warrant, which is needed for electronic communications in transit and has tougher legal requirements.

Essex County officials argued they were trying to access audio that had already been transmitted as opposed to live transmissions. The court agreed, ruling that law enforcement could use a data warrant.

According to Assistant Essex County Prosecutor Camila Garces, the court’s ruling “ensures that the state can access electronic footprints when conducting a criminal investigation.”

Defense attorney Lawrence Lustberg said that investigators should only have a right to see private message if they get a wiretap because they happen in real time.

“The court’s holding that seizing a tweet is not akin to a wiretap — with all of the protections that accompany wiretaps — fails to account for the reality of modern communication,” Lustberg said.

A spokesman for Twitter declined to comment on the ruling but pointed to the company’s guidelines for releasing users’ private information.

Twitter says that it requires a court order to disclose private information to authorities, that it alerts users about these disclosures when it is legally allowed to, that it stores some data for a limited period of time, and that it publishes annual transparency reports listing all such requests from law enforcement agencies.