I read that as the cop-bots were a force multiplier, not the entire force. You'd send them autonomously to do routine things like parking tickets, or dangerous things like armed response front-liners, but they would always be supervised or accompanied by a human operator except for extremely basic functions. And then during the apocalypse people desperately clung to whatever advantage they had, however limited in scope it might be.
This right here, which is the reason why "Zombie Cops" exist.
-snip-
1) Being able to tell Friend from Foe isn't actually that complicated, it is as simple as having a small chip on all of your "Friends" that identifies them as such. The military even uses the technology in the present day, and it in no way makes human operators obsolete.
2) It's not a "police officer" any more then a traffic camera is. I personally haven't heard of anyone sueing a police station for using traffic cameras, and the robot is basically just a slightly more intelligent, mobile, traffic camera.
3) They aren't armed with "lethal" weaponry, they are armed with batons (which are a traditionally non-lethal weapon).
4) Also keep in mind that they were previously connected to a larger network, which would allow them to query for confirmation if needed and prevent problems.
As for why/how they target humans but not zombies, here's what could have realistically happened:
1) A panicked programmer raises the threshold before force is allowed, and the point at which force should stop being applied to extremely high numbers. This is applied to all robots.
2) Due to bad programming friends aren't actually kept in a separate category, rather they just have their "danger" level set to an extremely low negative value.
3) The new thresholds add enough to outweigh the negative value, meaning friends are now targeted as foes.
4) Zombies either register as "non-human" or as "badly injured". Normally in a situation where an injured person instigates hostilities the main server is queried to determine whether intervention is required. Since the server cannot be queried (because the network is down) they are assumed innocent and not targeted.
5) Due to an old "remember friends/victims" setting, once the zombies are registered as something that isn't targeted they no longer are checked for hostility, resulting in the copbot's continued non-agression towards them.
Edit: Ninjas! Everywhere!