1
0
mirror of https://github.com/esphome/esphome.git synced 2025-10-07 04:13:47 +01:00

revert clang-tidy changes, copilot disagrees

This commit is contained in:
J. Nick Koston
2025-10-03 16:54:11 -05:00
parent 11b113b9db
commit 7621eb1f6e
3 changed files with 4 additions and 4 deletions

View File

@@ -22,7 +22,7 @@ class TextTraits {
int get_max_length() const { return this->max_length_; } int get_max_length() const { return this->max_length_; }
// Set/get the pattern. // Set/get the pattern.
void set_pattern(const std::string &pattern) { this->pattern_ = pattern; } void set_pattern(std::string pattern) { this->pattern_ = std::move(pattern); }
std::string get_pattern() const { return this->pattern_; } std::string get_pattern() const { return this->pattern_; }
StringRef get_pattern_ref() const { return StringRef(this->pattern_); } StringRef get_pattern_ref() const { return StringRef(this->pattern_); }

View File

@@ -131,8 +131,8 @@ class WebServerBase : public Component {
float get_setup_priority() const override; float get_setup_priority() const override;
#ifdef USE_WEBSERVER_AUTH #ifdef USE_WEBSERVER_AUTH
void set_auth_username(const std::string &auth_username) { credentials_.username = auth_username; } void set_auth_username(std::string auth_username) { credentials_.username = std::move(auth_username); }
void set_auth_password(const std::string &auth_password) { credentials_.password = auth_password; } void set_auth_password(std::string auth_password) { credentials_.password = std::move(auth_password); }
#endif #endif
void add_handler(AsyncWebHandler *handler); void add_handler(AsyncWebHandler *handler);

View File

@@ -35,7 +35,7 @@ class MultipartReader {
// Set callbacks for handling data // Set callbacks for handling data
void set_data_callback(DataCallback callback) { data_callback_ = std::move(callback); } void set_data_callback(DataCallback callback) { data_callback_ = std::move(callback); }
void set_part_complete_callback(const PartCompleteCallback &callback) { part_complete_callback_ = callback; } void set_part_complete_callback(PartCompleteCallback callback) { part_complete_callback_ = std::move(callback); }
// Parse incoming data // Parse incoming data
size_t parse(const char *data, size_t len); size_t parse(const char *data, size_t len);