@NYPDTransit/Twitter(NEW YORK) — A runaway dog wandering New York City’s subway tracks created a hairy situation for transit officials and commuters Friday afternoon.

The Metropolitan Transportation Authority (MTA) issued a service alert around 3:15 p.m. ET announcing changes and delays to the F train “because of a dog on the tracks” at York Street station in Brooklyn. A and C train riders also experienced delays as transit workers and police spent an hour trying to search and rescue the lost pup.

The dog, named Dakota, had escaped from a dog park in Brooklyn and somehow found its way onto the subway tracks, according to the New York City Transit Police Department. Police officers and transit workers eventually retrieved Dakota to safety.

According to ABC station WABC-TV, the dog was discovered on the tracks at Bergen Street station, two stops downtown from York Street.

Dakota was reunited with its owner, who took her beloved pup to the vet for a “minor injury,” police said.