From d89dea7000bbffb959302a724b003de28d753787 Mon Sep 17 00:00:00 2001 From: Ilia Ross Date: Fri, 15 Sep 2023 21:09:09 +0300 Subject: [PATCH] Fix Sent folder to be non-editable https://github.com/virtualmin/Virtualmin-Config/commit/b5c94dfc6671d47ffd569a3a843a0763f2d9af97#commitcomment-127407219 --- mailbox/list_folders.cgi | 4 ++-- mailbox/list_ifolders.cgi | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/mailbox/list_folders.cgi b/mailbox/list_folders.cgi index feee0ba1..7db714dc 100755 --- a/mailbox/list_folders.cgi +++ b/mailbox/list_folders.cgi @@ -42,8 +42,8 @@ print &ui_columns_start([ "", foreach my $f (@folders) { my @cols; my $deletable = 0; - if ($f->{'inbox'} || $f->{'drafts'} || $f->{'spam'}) { - # Inbox, drafs or spam folder which cannot be edited + if ($f->{'inbox'} || $f->{'drafts'} || $f->{'sent'} || $f->{'spam'}) { + # Inbox, drafs, sent or spam folder which cannot be edited push(@cols, &html_escape($f->{'name'})); } elsif ($f->{'type'} == 2) { diff --git a/mailbox/list_ifolders.cgi b/mailbox/list_ifolders.cgi index 4fca0ec7..64f7ea07 100755 --- a/mailbox/list_ifolders.cgi +++ b/mailbox/list_ifolders.cgi @@ -28,8 +28,8 @@ print &ui_columns_start([ "", foreach my $f (@folders) { my @cols; my $deletable = 0; - if ($f->{'inbox'} || $f->{'drafts'} || $f->{'spam'}) { - # Inbox, drafs or spam folder which cannot be edited + if ($f->{'inbox'} || $f->{'drafts'} || $f->{'sent'} || $f->{'spam'}) { + # Inbox, drafs, sent or spam folder which cannot be edited push(@cols, &html_escape($f->{'name'})); push(@cols, "IMAP"); push(@cols, &nice_size(&folder_size($f)));