Long Island police say two men ordered Chinese food so they could attack and rob the deliveryman, and then attempted the scheme again but were caught by officers.

Devon Williams, 20, and Ramone Bartley, 24, both of Queens, were arrested on robbery and menacing charges Wednesday night.

Police say the two men ordered Chinese food in Malverne Tuesday night. When the 36-year-old deliveryman arrived at the Webster Street address, one of the suspects allegedly took a wooden object and hit him over the head. That suspect then allegedly took the deliveryman’s wallet and the cash inside, police said.

The deliveryman’s head was cut open and he was taken to an area hospital for treatment.

But the suspects weren’t done, according to police.

On Wednesday, officers on patrol spotted a suspicious vehicle parked on Coolidge Street in Malverne, an area near the previous robbery. Williams and Bartley were inside the vehicle.

At some point a Chinese food deliveryman happened upon the street. The officers found out that the two men were allegedly about to to rob the deliveryman and arrested both of them.

The suspects were scheduled to be arraigned Friday in Hempstead.