From 6159a74d4189ce1224317fad9c9e98de612c5e58 Mon Sep 17 00:00:00 2001 From: Ben Dailey Date: Thu, 3 Oct 2024 11:59:08 -0400 Subject: [PATCH] Clean up unneeded code --- src/zm_monitor.h | 6 ------ src/zm_monitor_onvif.cpp | 9 --------- 2 files changed, 15 deletions(-) diff --git a/src/zm_monitor.h b/src/zm_monitor.h index 70fc04659..8760fbf3c 100644 --- a/src/zm_monitor.h +++ b/src/zm_monitor.h @@ -329,9 +329,6 @@ class Monitor : public std::enable_shared_from_this { bool healthy; std::string last_topic; std::string last_value; - std::string last_active_topic; - std::string last_active_value; - std::string GetNoteText(); void SetNoteSet(Event::StringSet ¬eSet); #ifdef WITH_GSOAP struct soap *soap = nullptr; @@ -353,9 +350,6 @@ class Monitor : public std::enable_shared_from_this { bool isAlarmed() const { return alarmed; }; void setAlarmed(bool p_alarmed) { alarmed = p_alarmed; }; bool isHealthy() const { return healthy; }; - const std::string &lastTopic() const { return last_active_topic; }; - const std::string &lastValue() const { return last_active_value; }; - const std::string noteText() { return GetNoteText(); }; void setNotes(Event::StringSet ¬eSet) { SetNoteSet(noteSet); }; }; diff --git a/src/zm_monitor_onvif.cpp b/src/zm_monitor_onvif.cpp index 717ff2db1..9d168d07e 100644 --- a/src/zm_monitor_onvif.cpp +++ b/src/zm_monitor_onvif.cpp @@ -202,8 +202,6 @@ void Monitor::ONVIF::WaitForMessage() { if (alarms.count(last_topic) == 0 ) { alarms[last_topic] = last_value; - last_active_topic = last_topic; - last_active_value = last_value; if (!alarmed) { Info("Triggered Start Event on ONVIF"); alarmed = true; @@ -286,13 +284,6 @@ int SOAP_ENV__Fault(struct soap *soap, char *faultcode, char *faultstring, char } #endif -std::string Monitor::ONVIF::GetNoteText() { - std::string note = ""; - #ifdef WITH_GSOAP - note = last_active_topic + "/" + last_active_value; - #endif - return note; -} void Monitor::ONVIF::SetNoteSet(Event::StringSet ¬eSet) { std::string note = ""; #ifdef WITH_GSOAP