Section 158. A police officer, constable or animal control officer may capture, detain or, in the case of a threat to public safety, euthanize a dog in a humane manner if found to be in violation of an order of a hearing authority or a district court and may euthanize a dog, in a humane manner, if it is living in a wild state.