1
0
mirror of https://github.com/esphome/esphome.git synced 2025-11-18 15:55:46 +00:00
This commit is contained in:
J. Nick Koston
2025-11-06 17:26:51 -06:00
parent 3b9570d916
commit 0893de4f29
2 changed files with 2 additions and 3 deletions

View File

@@ -396,7 +396,7 @@ bool WiFiComponent::sync_selected_sta_to_best_scan_result_() {
return false; return false;
} }
WiFiAP WiFiComponent::get_sta() { WiFiAP WiFiComponent::get_sta() const {
const WiFiAP *config = this->get_selected_sta_(); const WiFiAP *config = this->get_selected_sta_();
return config ? *config : WiFiAP{}; return config ? *config : WiFiAP{};
} }

View File

@@ -218,8 +218,7 @@ class WiFiComponent : public Component {
WiFiComponent(); WiFiComponent();
void set_sta(const WiFiAP &ap); void set_sta(const WiFiAP &ap);
// Returns a copy of the currently selected AP configuration // Returns a copy of the currently selected AP configuration (88 bytes)
// Note: This copies the 88-byte WiFiAP. Only used by WiFiConfigureAction for state save/restore.
WiFiAP get_sta() const; WiFiAP get_sta() const;
void init_sta(size_t count); void init_sta(size_t count);
void add_sta(const WiFiAP &ap); void add_sta(const WiFiAP &ap);