}
}
-static void lazy_expunge_mail_namespace_storage_added(struct mail_namespace *ns)
+static void lazy_expunge_mailbox_list_created(struct mailbox_list *list)
{
- struct mailbox_list *list = ns->list;
struct lazy_expunge_mail_user *luser =
- LAZY_EXPUNGE_USER_CONTEXT(ns->user);
+ LAZY_EXPUNGE_USER_CONTEXT(list->ns->user);
struct lazy_expunge_mailbox_list *llist;
const char *const *p;
unsigned int i;
quota plugin sees it */
p = t_strsplit_spaces(luser->env, " ");
for (i = 0; i < LAZY_NAMESPACE_COUNT && *p != NULL; i++, p++) {
- if (strcmp(ns->prefix, *p) == 0) {
- ns->flags |= NAMESPACE_FLAG_NOQUOTA;
+ if (strcmp(list->ns->prefix, *p) == 0) {
+ list->ns->flags |= NAMESPACE_FLAG_NOQUOTA;
break;
}
}
- if (luser != NULL && ns->type == NAMESPACE_PRIVATE) {
+ if (luser != NULL && list->ns->type == NAMESPACE_PRIVATE) {
llist = p_new(list->pool, struct lazy_expunge_mailbox_list, 1);
MODULE_CONTEXT_SET(list, lazy_expunge_mailbox_list_module,
llist);
static struct mail_storage_hooks lazy_expunge_mail_storage_hooks = {
.mail_user_created = lazy_expunge_mail_user_created,
.mail_namespaces_created = lazy_expunge_mail_namespaces_created,
- .mail_namespace_storage_added = lazy_expunge_mail_namespace_storage_added,
+ .mailbox_list_created = lazy_expunge_mailbox_list_created,
.mailbox_allocated = lazy_expunge_mailbox_allocated,
.mail_allocated = lazy_expunge_mail_allocated
};