Skip to content

Commit

Permalink
Fixup: don't else after return and no det. notice
Browse files Browse the repository at this point in the history
  • Loading branch information
Gliese852 committed Sep 6, 2023
1 parent a5184dc commit 40720bb
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion howdy/src/config.ini
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

[core]
# Print that face detection is being attempted
detection_notice = true
detection_notice = false

# Print that face detection has timed out
timeout_notice = true
Expand Down
4 changes: 3 additions & 1 deletion howdy/src/pam/main.cc
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,9 @@ auto identify(pam_handle_t *pamh, int flags, int argc, const char **argv,
if (!std::ifstream(model_path)) {
return howdy_status(username, CompareError::NO_FACE_MODEL, config,
conv_function);
} else if (config.GetBoolean("core", "detection_notice", true)) {
}

if (config.GetBoolean("core", "detection_notice", true)) {
if ((conv_function(PAM_TEXT_INFO, S("Attempting facial authentication"))) !=
PAM_SUCCESS) {
syslog(LOG_ERR, "Failed to send detection notice");
Expand Down

0 comments on commit 40720bb

Please sign in to comment.