Skip to content

Commit

Permalink
Do not validate OTP secret when it is not set
Browse files Browse the repository at this point in the history
Fixes #209
  • Loading branch information
szszszsz committed Apr 3, 2017
1 parent 018708a commit dfc7da1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/ui/mainwindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -660,7 +660,7 @@ void MainWindow::on_writeButton_clicked() {
} else {
generateTOTPConfig(&otp);
}
if (!validate_secret(otp.secret)) {
if (!this->ui->secretEdit->text().isEmpty() && !validate_secret(otp.secret)) {
return;
}
if(auth_admin.authenticate()){
Expand Down

0 comments on commit dfc7da1

Please sign in to comment.