diff options
author | Daniel Vassdal <shutter@canternet.org> | 2015-02-21 12:46:40 +0100 |
---|---|---|
committer | Daniel Vassdal <shutter@canternet.org> | 2015-02-22 14:38:38 +0100 |
commit | 75e7eaceba5031927445d5fc9861c8c107fdaa8f (patch) | |
tree | 055430ead556f6ec6326543124df87ec79e91dba /src | |
parent | 0a195d3dc2a1d3f63560d8010cde5cb89e025cd9 (diff) |
m_sqloper.cpp: Add support for the `active` column
When active is true the user is allowed to log in. When it is FALSE, he is not.
2.0 users must alter their table (or view) so that it contains this field.
Diffstat (limited to 'src')
-rw-r--r-- | src/modules/m_sqloper.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/modules/m_sqloper.cpp b/src/modules/m_sqloper.cpp index bc46bd7e7..b5f0d6c47 100644 --- a/src/modules/m_sqloper.cpp +++ b/src/modules/m_sqloper.cpp @@ -122,7 +122,7 @@ public: SQL.SetProvider("SQL/" + dbid); hashtype = tag->getString("hash"); - query = tag->getString("query", "SELECT hostname as host, type FROM ircd_opers WHERE username='$username' AND password='$password'"); + query = tag->getString("query", "SELECT hostname as host, type FROM ircd_opers WHERE username='$username' AND password='$password' AND active=1;"); } ModResult OnPreCommand(std::string &command, std::vector<std::string> ¶meters, LocalUser *user, bool validated, const std::string &original_line) CXX11_OVERRIDE |