WASHINGTON (AP) — The Supreme Court seems unsure of whether it’s legal for a state to block out-of-staters from getting public documents through its Freedom of Information Act law.

Justices on Wednesday heard arguments from men from California and Rhode Island, who wanted to use the Virginia FOIA law to get state documents, but were denied because they are not Virginia citizens. Virginia’s FOIA law limits access to state citizens and some media outlets. But the two men say it is unconstitutional to not allow everyone access to the protections of a state’s FOIA law.

Justices noted that states can legally block out-of-staters from doing things like voting and hunting big game. But they also noted that state records can be used in commerce, which is supposed to move freely across state lines.