Fallback to a 30 second period if an andOTP doesn't provide one

pull/53/head
Alexander Bakker 6 years ago
parent a251685002
commit 4c1dec613c

@ -69,7 +69,7 @@ public class AndOtpFileImporter extends DatabaseFileImporter {
info = new TotpInfo(secret, algo, digits, obj.getInt("period"));
break;
case "steam":
info = new SteamInfo(secret, algo, digits, obj.getInt("period"));
info = new SteamInfo(secret, algo, digits, obj.optInt("period", 30));
break;
default:
throw new DatabaseImporterException("unsupported otp type: " + type);

Loading…
Cancel
Save