I depends on what you mean by public safety. They certainly have a duty to protect the general public's safety. This is why they win most 2A cases. What is not really true is that this means they protect everyone in all situations. They do not have a duty protect individuals. What is unclear is where the line between an individual and the public in general.
I always took that to mean that they (the entire law enforcement stack ... cops, prosecutors, DAs, all of it) protect society by enforcing the rule of law when it's been violated. The theory being that an environment in which prospective criminals know the consequences if they're caught is one in which at least some crime is less likely to happen. That has a slightly preventative effect, but isn't to be confused with law enforcers likely being there to help physically prevent a given single crime (let alone being obliged to do so).
The presence of law enforcement as a crime is unfolding or about to do so provides a better than usual opportunity to attempt to mitigate it, but that's just frosting on the law enforcement cake, and not the mission or duty, per se.
The entire notion of individual people not needing (and thus not being allowed to have) the means of self defense because the government plays that role ... is EXACTLY the BS argument that the founders anticipated, and what the 2A is explicitly written to smack down. In essence: "Yeah, turns out we'll need a professional military to protect our national freedom, but that's no excuse to take away the individual liberty to keep and bear personal arms, so that's not allowed."
The founders knew people would trot out that absurd (in both practical and philosophical terms) concept, and wrote in protection against it right after the protection of speech and assembly as fundamental to our liberties. Believe me, I'd rather have a cop dive in to deal with a threatening situation if that can be arranged. But most threatening situations aren't bank hostage standoffs with time for everyone to get on the chessboard and play their parts. More like: getting approached in a dark parking lot (or as the founders understood it ... on your farm, or along a dark road in the woods, etc), with the situation ending one way or another in seconds.
Public safety, in that context, never has been and never can be in the hands of law enforcement.