diff options
| author | 2014-11-01 18:17:04 +0100 | |
|---|---|---|
| committer | 2014-11-01 18:17:04 +0100 | |
| commit | fbc73e20784b055485f676096e758d6aeed62e0c (patch) | |
| tree | 8251c8473af414527becb989558a69c4e7dc49b4 /src/modules/m_dccallow.cpp | |
| parent | Remove if (!this) check from ConfigTag::readString() (diff) | |
Add stdalgo::erase() and use it to simplify code
Diffstat (limited to 'src/modules/m_dccallow.cpp')
| -rw-r--r-- | src/modules/m_dccallow.cpp | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/src/modules/m_dccallow.cpp b/src/modules/m_dccallow.cpp index cc7fbd323..1b838be5c 100644 --- a/src/modules/m_dccallow.cpp +++ b/src/modules/m_dccallow.cpp @@ -268,11 +268,7 @@ class ModuleDCCAllow : public Module // remove their DCCALLOW list if they have one if (udl) - { - userlist::iterator it = std::find(ul.begin(), ul.end(), user); - if (it != ul.end()) - ul.erase(it); - } + stdalgo::erase(ul, user); // remove them from any DCCALLOW lists // they are currently on |
