summaryrefslogtreecommitdiff
path: root/src/cull_list.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/cull_list.cpp')
-rw-r--r--src/cull_list.cpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/cull_list.cpp b/src/cull_list.cpp
index a8188701a..b7254fd0b 100644
--- a/src/cull_list.cpp
+++ b/src/cull_list.cpp
@@ -87,6 +87,12 @@ CullItem::CullItem(userrec* u, std::string &r)
this->reason = r;
}
+CullItem::CullItem(userrec* u, const char* r)
+{
+ this->user = u;
+ this->reason = r;
+}
+
userrec* CullItem::GetUser()
{
return this->user;
@@ -113,6 +119,16 @@ void CullList::AddItem(userrec* user, std::string &reason)
}
}
+void CullList::AddItem(userrec* user, const char* reason)
+{
+ if (exempt.find(user) == exempt.end())
+ {
+ CullItem item(user,reason);
+ list.push_back(item);
+ exempt[user] = user->signon;
+ }
+}
+
int CullList::Apply()
{
int n = 0;