mirror of
https://github.com/esphome/esphome.git
synced 2024-12-29 08:51:43 +01:00
Fix linting issues
This commit is contained in:
parent
c72bb488f2
commit
4ba9392325
4 changed files with 15 additions and 14 deletions
|
@ -7,7 +7,7 @@ from esphome.const import (
|
|||
CONF_UUID,
|
||||
CONF_SERVICES,
|
||||
CONF_VALUE,
|
||||
CONF_MAX_LENGTH
|
||||
CONF_MAX_LENGTH,
|
||||
)
|
||||
from esphome.components import esp32_ble
|
||||
from esphome.core import CORE
|
||||
|
@ -65,7 +65,7 @@ PROPERTIES_SCHEMA = cv.All(
|
|||
upper=True,
|
||||
)
|
||||
),
|
||||
cv.Length(min=1)
|
||||
cv.Length(min=1),
|
||||
)
|
||||
|
||||
UUID_SCHEMA = cv.Any(cv.All(cv.string, validate_uuid), cv.hex_uint32_t)
|
||||
|
@ -202,7 +202,7 @@ async def to_code(config):
|
|||
char_conf[CONF_ID],
|
||||
service_var.create_characteristic(
|
||||
parse_uuid(char_conf[CONF_UUID]),
|
||||
parse_properties(char_conf[CONF_PROPERTIES])
|
||||
parse_properties(char_conf[CONF_PROPERTIES]),
|
||||
),
|
||||
)
|
||||
if CONF_ON_WRITE in char_conf:
|
||||
|
@ -233,6 +233,7 @@ async def to_code(config):
|
|||
if CORE.using_esp_idf:
|
||||
add_idf_sdkconfig_option("CONFIG_BT_ENABLED", True)
|
||||
|
||||
|
||||
@automation.register_action(
|
||||
"ble_server.characteristic_set_value",
|
||||
BLECharacteristicSetValueAction,
|
||||
|
|
|
@ -63,7 +63,7 @@ void BLEService::emit_client_connect(const uint16_t conn_id) {
|
|||
this->on_client_connect_(conn_id);
|
||||
}
|
||||
|
||||
void emit_client_disconnect(const uint16_t conn_id) {
|
||||
void BLEService::emit_client_disconnect(const uint16_t conn_id) {
|
||||
if (this->on_client_disconnect_ && this->is_running())
|
||||
this->on_client_disconnect_(conn_id);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue