Skip to content

Commit 1a5b276

Browse files
ci(pre-commit): Apply automatic fixes
1 parent 673ba34 commit 1a5b276

File tree

3 files changed

+8
-9
lines changed

3 files changed

+8
-9
lines changed

libraries/BLE/examples/Notify/Notify.ino

+2-2
Original file line numberDiff line numberDiff line change
@@ -68,12 +68,12 @@ void setup() {
6868
BLECharacteristic::PROPERTY_READ | BLECharacteristic::PROPERTY_WRITE | BLECharacteristic::PROPERTY_NOTIFY | BLECharacteristic::PROPERTY_INDICATE
6969
);
7070

71-
// Creates BLE Descriptor 0x2902: Client Characteristic Configuration Descriptor (CCCD)
71+
// Creates BLE Descriptor 0x2902: Client Characteristic Configuration Descriptor (CCCD)
7272
pCharacteristic->addDescriptor(new BLE2902());
7373
// Adds also the Characteristic User Description - 0x2901 descriptor
7474
descriptor_2901 = new BLE2901();
7575
descriptor_2901->setDescription("My own description for this characteristic.");
76-
descriptor_2901->setAccessPermissions(ESP_GATT_PERM_READ); // enforce read only - default is Read|Write
76+
descriptor_2901->setAccessPermissions(ESP_GATT_PERM_READ); // enforce read only - default is Read|Write
7777
pCharacteristic->addDescriptor(descriptor_2901);
7878

7979
// Start the service

libraries/BLE/src/BLE2901.cpp

+3-4
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/*
22
BLE2901.h
3-
3+
44
GATT Descriptor 0x2901 Characteristic User Description
55
66
The value of this description is a user-readable string
@@ -23,16 +23,15 @@
2323

2424
#include "BLE2901.h"
2525

26-
BLE2901::BLE2901() : BLEDescriptor(BLEUUID((uint16_t)0x2901)) {
27-
} // BLE2901
26+
BLE2901::BLE2901() : BLEDescriptor(BLEUUID((uint16_t)0x2901)) {} // BLE2901
2827

2928
/**
3029
* @brief Set the Characteristic User Description
3130
*/
3231
void BLE2901::setDescription(String userDesc) {
3332
if (userDesc.length() > ESP_GATT_MAX_ATTR_LEN) {
3433
log_e("Size %d too large, must be no bigger than %d", userDesc.length(), ESP_GATT_MAX_ATTR_LEN);
35-
return;
34+
return;
3635
}
3736
setValue(userDesc);
3837
}

libraries/BLE/src/BLE2901.h

+3-3
Original file line numberDiff line numberDiff line change
@@ -27,9 +27,9 @@
2727
#include "BLEDescriptor.h"
2828

2929
class BLE2901 : public BLEDescriptor {
30-
public:
31-
BLE2901();
32-
void setDescription(String desc);
30+
public:
31+
BLE2901();
32+
void setDescription(String desc);
3333
}; // BLE2901
3434

3535
#endif /* CONFIG_BLUEDROID_ENABLED */

0 commit comments

Comments
 (0)