diff --git a/lib/ocpp/v16/charge_point_impl.cpp b/lib/ocpp/v16/charge_point_impl.cpp index bb48c5815..beae01243 100644 --- a/lib/ocpp/v16/charge_point_impl.cpp +++ b/lib/ocpp/v16/charge_point_impl.cpp @@ -1355,14 +1355,14 @@ void ChargePointImpl::execute_connectors_availability_change(const std::vectorstatus->submit_event(connector, FSMEvent::BecomeAvailable, ocpp::DateTime()); } - if (connector != 0 and this->enable_evse_callback != nullptr) { + if (this->enable_evse_callback != nullptr) { this->enable_evse_callback(connector); } } else { if (connector == 0 or !evse_changed) { this->status->submit_event(connector, FSMEvent::ChangeAvailabilityToUnavailable, ocpp::DateTime()); } - if (connector != 0 and this->disable_evse_callback != nullptr) { + if (this->disable_evse_callback != nullptr) { this->disable_evse_callback(connector); } }