Skip to content

Commit 1832bfb

Browse files
authoredDec 2, 2023
Merge pull request #122 from IhorNehrutsa/cppcheck
Fix funcArgNamesDifferent with cppcheck
2 parents 5157fc5 + 2de5bae commit 1832bfb

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed
 

‎src/OneButton.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -257,7 +257,7 @@ void OneButton::_fsm(bool activeLevel)
257257
_newState(OneButton::OCS_UP);
258258
_startTime = now; // remember starting time
259259

260-
} else if ((activeLevel) && (waitTime > _press_ms)) {
260+
} else if (waitTime > _press_ms) {
261261
if (_longPressStartFunc) _longPressStartFunc();
262262
if (_paramLongPressStartFunc) _paramLongPressStartFunc(_longPressStartFuncParam);
263263
_newState(OneButton::OCS_PRESS);

‎src/OneButton.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@ class OneButton
137137
* level is given by the parameter.
138138
* Run the finite state machine (FSM) using the given level.
139139
*/
140-
void tick(bool level);
140+
void tick(bool activeLevel);
141141

142142

143143
/**

0 commit comments

Comments
 (0)
Please sign in to comment.