def deletePerson(self, pid): dao = PersonDAO() if not dao.getPersonById(pid): return jsonify(Error="Person not found."), 404 else: dao.delete(pid) return jsonify(DeleteStatus="OK"), 200
def deletePerson(self, perid): dao = PersonDAO() id = dao.delete(perid) return jsonify(DeleteStatus='OK'), 200