mirror of
https://git.tt-rss.org/git/tt-rss.git
synced 2025-12-16 03:25:57 +00:00
use separate database column for OTP secrets (migrate previous format if needed)
This commit is contained in:
@@ -119,6 +119,11 @@ class Pref_Users extends Handler_Administrative {
|
||||
$user->email = clean($_REQUEST["email"]);
|
||||
$user->otp_enabled = checkbox_to_sql_bool($_REQUEST["otp_enabled"]);
|
||||
|
||||
// force new OTP secret when next enabled
|
||||
if (Config::get_schema_version() >= 143 && !$user->otp_enabled) {
|
||||
$user->otp_secret = null;
|
||||
}
|
||||
|
||||
$user->save();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user