Skip to content

Commit

Permalink
Simplified from suggestions
Browse files Browse the repository at this point in the history
  • Loading branch information
jslay88 authored and timum-viw committed Jan 16, 2020
1 parent be273c0 commit 01ebdcd
Showing 1 changed file with 1 addition and 9 deletions.
10 changes: 1 addition & 9 deletions examples/BasicExample/ESP32BasicExample.ino
Original file line number Diff line number Diff line change
Expand Up @@ -67,10 +67,6 @@ void LEDStateChange(const bool newState) {

void checkLEDState() {
digitalWrite(LEDPin, LEDState);
digitalWrite(LEDPin, LOW);
} else {
digitalWrite(LEDPin, HIGH);
}
const bool newState = digitalRead(buttonPin); // See if button is physically pushed
if (!newState) {
LEDStateChange(!LEDState);
Expand Down Expand Up @@ -112,11 +108,7 @@ void setup() {

// Setup Connection
if (useSSL) {
if (sslFingerprint) {
webSocket.beginSSL(host, port, path, sslFingerprint);
} else {
webSocket.beginSSL(host, port, path);
}
webSocket.beginSSL(host, port, path, sslFingerprint);
} else {
webSocket.begin(host, port, path);
}
Expand Down

0 comments on commit 01ebdcd

Please sign in to comment.