diff options
| author | Sadie Powell <sadie@witchery.services> | 2021-08-01 19:23:48 +0100 |
|---|---|---|
| committer | Sadie Powell <sadie@witchery.services> | 2021-08-01 19:23:48 +0100 |
| commit | e7e8447fa39ced57743eab51e8e2835ddddd7001 (patch) | |
| tree | 2bc8d31f575616e612c0d7e3898bd94bd9165b18 /src | |
| parent | 561b205c4a3a125c12a7926ef18fa1eb822c387c (diff) | |
Deduplicate code for checking if a user is securely connected.
Diffstat (limited to 'src')
| -rw-r--r-- | src/users.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/users.cpp b/src/users.cpp index 1f0af4f63..c5fbfdcdb 100644 --- a/src/users.cpp +++ b/src/users.cpp @@ -448,6 +448,11 @@ bool User::IsRecognized(bool check_secure) const return on_access; } +bool User::IsSecurelyConnected() const +{ + return HasMode("SSL") || HasExt("ssl"); +} + bool User::IsServicesOper() { if (!this->nc || !this->nc->IsServicesOper()) |
