Skip to content

Commit

Permalink
Skip processing on 0-length key
Browse files Browse the repository at this point in the history
  • Loading branch information
lbussy committed Mar 23, 2020
1 parent f98da0d commit 497746f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/bftarget.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ BFTarget* BFTarget::getInstance() {

bool BFTarget::push() {
Log.verbose(F("Triggered %s push." CR), single->target->target.name);
if (single->target->apiName.enabled && sizeof(config.brewersfriend.key)) { // Key target is unique per target (for now)
if (single->target->apiName.enabled && strlen(config.brewersfriend.key)) { // Key target is unique per target (for now)
single->target->target.enabled = true;
strlcpy(single->target->key.name, config.brewersfriend.key, sizeof(config.brewersfriend.key)); // Key target is unique per target (for now)
} else {
Expand Down

0 comments on commit 497746f

Please sign in to comment.