mirror of
https://github.com/znc/znc.git
synced 2026-06-26 13:01:44 +02:00
Prefer Contains() over find() != npos
This commit is contained in:
+1
-1
@@ -1220,7 +1220,7 @@ bool CUser::DelCTCPReply(const CString& sCTCP) {
|
||||
}
|
||||
|
||||
bool CUser::SetStatusPrefix(const CString& s) {
|
||||
if ((!s.empty()) && (s.length() < 6) && (s.find(' ') == CString::npos)) {
|
||||
if ((!s.empty()) && (s.length() < 6) && (!s.Contains(" "))) {
|
||||
m_sStatusPrefix = (s.empty()) ? "*" : s;
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user