One group called Melinda Pavey's comment “heartless” in the wake of several road deaths.

An Australian state government minister has come under fire for appearing to suggest that tired or distracted drivers could be given electric shocks to prevent crashes.

It has been a horror week on roads in the state of New South Wales, with three deadly crashes in two days, including a seven-vehicle collision on a rural highway in which two people died and more than a dozen were injured. Even before those crashes, 19 people had died on the state’s roads in just 15 days.

On Wednesday, New South Wales roads minister Melinda Pavey announced extra funding for technology around crash testing, driver assistance and vehicle safety. In the process, she said that “technology now is so advanced, a driver can be driving and get an electric shock if they look away from the windscreen for more than two seconds.”

Pavey has been roundly panned for her statement.

“To not only ignore the actual problems that are killing people on our roads, but to also propose electrocuting people driving heavy vehicles, is not only baffling and deeply offensive to the families of those killed, it is also unconscionably dangerous in its negligence,” the Transport Workers Union said in a statement.

The union called her comments “heartless, arrogant and completely incompetent.”

In only 24 hours, five people in NSW have been killed in three truck-related crashes. Rather than address the extreme and unfair working conditions that are causing truck deaths, NSW Roads Minister @melindapaveyMP has seriously suggested *electrocuting drivers behind the wheel*. pic.twitter.com/ZGmzJrEAFF

Pavey’s office told HuffPost her comments had been taken out of context, and that she was speaking generally about how far vehicle safety technology has progressed, not explicitly advocating shocks for drivers.

A spokeswoman for Pavey also pointed out that shock devices for drivers already exist, such as the Steer bracelet, which sends vibrations and shocks to drivers if their heart rate drops, a signal that they may be falling asleep or getting drowsy.

“I am both disgusted and appalled that today of all days the Transport Workers Union would play this kind of politics,” Pavey said in a statement to HuffPost.

“I spoke on other forms of technology being looked at in both the private and public sectors – specifically important measures around fatigue management. New technology for fatigue management are currently in place in Australia and being rolled out across fleets by our most responsible operators, and further research continues to highlight new measures.”

“If a driver is a fluttering their eyes in tiredness or looking away, there are a variety of measures that can alert the driver,” she told the site. “That can be through an electronic jab through the seat that gives a slight buzz or a message and some of our best companies are using that technology and investing in their workforce and safety.”

“If we can’t have a decent honest conversation about the technology available, we have some issues,” she added. “It’s not the time to put our heads in the sand ... It has been a struggle for some drivers to be monitored ... but many have embraced it because they want to return to their families at the end of the day.”