mirror of
https://github.com/transmission/transmission.git
synced 2026-04-17 23:54:19 +01:00
fix: use one variable to store TR_KEY_rpc_authentication_required (#6514)
This commit is contained in:
@@ -832,7 +832,7 @@ void tr_rpc_server::setPassword(std::string_view password) noexcept
|
||||
|
||||
void tr_rpc_server::setPasswordEnabled(bool enabled)
|
||||
{
|
||||
is_password_enabled_ = enabled;
|
||||
authentication_required_ = enabled;
|
||||
tr_logAddDebug(fmt::format("setting password-enabled to '{}'", enabled));
|
||||
}
|
||||
|
||||
|
||||
@@ -100,7 +100,7 @@ public:
|
||||
|
||||
[[nodiscard]] constexpr auto isPasswordEnabled() const noexcept
|
||||
{
|
||||
return is_password_enabled_;
|
||||
return authentication_required_;
|
||||
}
|
||||
|
||||
void setPasswordEnabled(bool enabled);
|
||||
@@ -161,6 +161,4 @@ public:
|
||||
|
||||
size_t login_attempts_ = 0U;
|
||||
int start_retry_counter = 0;
|
||||
|
||||
bool is_password_enabled_ = false;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user