BROOKLYN, N.Y. (PIX11) — Police on Sunday arrested an alleged attacker accused of chasing a man in a subway station and knocking the victim and himself onto the tracks.

Anthony Melendez, 35, was taken into custody on charges of assault, reckless endangerment and criminal possession of a weapon, police said. The NYPD released video of the incident less than 24 hours before Melendez’ arrest.

Video shows the 52-year-old victim on a southbound platform at the Broadway Junction station on Wednesday. Melendez allegedly approached and started a verbal dispute, then pulled out a knife and chased the victim.

Security footage shows the moment the pair fell from the platform onto the tracks. Both men were able to get back onto the platform before any trains came, police said. During the struggle, the victim was slashed in the chest, ear, finger and head and received treatment for his injuries.