X-Git-Url: https://git.stg.codes/stg.git/blobdiff_plain/e19060886ea59cbcb0c97e1712a954f729ef47b3..e3bd9717d35cb33018fb7589e1dfc7751d193b33:/projects/stargazer/plugins/other/smux/sensors.h diff --git a/projects/stargazer/plugins/other/smux/sensors.h b/projects/stargazer/plugins/other/smux/sensors.h index 7c11751e..3337323e 100644 --- a/projects/stargazer/plugins/other/smux/sensors.h +++ b/projects/stargazer/plugins/other/smux/sensors.h @@ -18,6 +18,7 @@ class Sensor { public: + virtual ~Sensor() {} virtual bool GetValue(ObjectSyntax_t * objectSyntax) const = 0; #ifdef DEBUG virtual std::string ToString() const = 0; @@ -159,7 +160,7 @@ class TariffChangeUsersSensor : public UsersSensor { private: bool UserPredicate(USER_PTR userPtr) const - { return userPtr->GetProperty().nextTariff.ConstData().empty(); } + { return !userPtr->GetProperty().nextTariff.ConstData().empty(); } }; class TotalTariffsSensor : public Sensor { @@ -280,11 +281,13 @@ class ConstSensor : public Sensor { T value; }; +#ifdef DEBUG template <> inline std::string ConstSensor::ToString() const { return value; } +#endif #endif