summaryrefslogtreecommitdiff
path: root/src/core/cs_access.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/cs_access.c')
-rw-r--r--src/core/cs_access.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/core/cs_access.c b/src/core/cs_access.c
index 00af72a88..08680a989 100644
--- a/src/core/cs_access.c
+++ b/src/core/cs_access.c
@@ -324,7 +324,12 @@ class CommandCSAccess : public Command
/* We don't know the nick if someone used numbers, so we trigger the event without
* nick param. We just do this once, even if someone enters a range. -Certus */
- FOREACH_MOD(I_OnAccessDel, OnAccessDel(ci, u, (na->nick ? na->nick : NULL)));
+ /* Only call this event if na exists (if they deleted by user, not numlist).
+ * The callback for deleting by numlist will call this event otherwise - Adam */
+ if (na)
+ {
+ FOREACH_MOD(I_OnAccessDel, OnAccessDel(ci, u, na->nick));
+ }
}
}
else if (cmd == "LIST")