diff options
Diffstat (limited to 'src/mongo/db/commands/authentication_commands.cpp')
-rw-r--r-- | src/mongo/db/commands/authentication_commands.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/mongo/db/commands/authentication_commands.cpp b/src/mongo/db/commands/authentication_commands.cpp index 58e34b87f9d..0b925c3d84c 100644 --- a/src/mongo/db/commands/authentication_commands.cpp +++ b/src/mongo/db/commands/authentication_commands.cpp @@ -97,8 +97,8 @@ class CmdGetNonce : public BasicCommand { public: CmdGetNonce() : BasicCommand("getnonce"), _random(SecureRandom::create()) {} - bool slaveOk() const final { - return true; + AllowedOnSecondary secondaryAllowed() const override { + return AllowedOnSecondary::kAlways; } std::string help() const final { @@ -259,8 +259,8 @@ CmdAuthenticate cmdAuthenticate; class CmdLogout : public BasicCommand { public: - virtual bool slaveOk() const { - return true; + AllowedOnSecondary secondaryAllowed() const override { + return AllowedOnSecondary::kAlways; } virtual void addRequiredPrivileges(const std::string& dbname, const BSONObj& cmdObj, |