Use refernece to avoid ctor/dtor

Use PinManager to determine reserved pins
This commit is contained in:
Blaz Kristan
2024-09-14 14:54:42 +02:00
parent e3d9417b84
commit 81e412fe5b
2 changed files with 20 additions and 32 deletions

View File

@@ -1271,7 +1271,7 @@ void WS2812FX::finalizeInit() {
bool clash;
do {
clash = false;
for (const auto pin : defDataPins) {
for (const auto &pin : defDataPins) {
if (pin == defPin[j]) {
defPin[j]++;
if (defPin[j] < WLED_NUM_PINS) clash = true;