mirror of
https://github.com/freescout-helpdesk/freescout.git
synced 2024-11-25 03:43:33 +01:00
Removing INBOX as default IMAP folder
This commit is contained in:
parent
180380339d
commit
a51189e6f6
@ -107,14 +107,7 @@ class FetchEmails extends Command
|
||||
// Connect to the Server
|
||||
$client->connect();
|
||||
|
||||
// Get INBOX folder
|
||||
$folders = [];
|
||||
$folder = $client->getFolder('INBOX');
|
||||
|
||||
if (!$folder) {
|
||||
throw new \Exception('Could not get mailbox folder: INBOX', 1);
|
||||
}
|
||||
$folders[] = $folder;
|
||||
|
||||
// Fetch emails from custom IMAP folders.
|
||||
if ($mailbox->in_protocol == Mailbox::IN_PROTOCOL_IMAP) {
|
||||
|
@ -325,10 +325,8 @@ class MailboxesController extends Controller
|
||||
// Save all custom folders except INBOX.
|
||||
$in_imap_folders = [];
|
||||
foreach ($request->in_imap_folders as $imap_folder) {
|
||||
if (mb_strtolower($imap_folder) != 'inbox') {
|
||||
$in_imap_folders[] = $imap_folder;
|
||||
}
|
||||
}
|
||||
$mailbox->setInImapFolders($in_imap_folders);
|
||||
|
||||
$mailbox->save();
|
||||
|
@ -126,7 +126,6 @@
|
||||
|
||||
<div class="col-sm-6 flexy">
|
||||
<select id="in_imap_folders" class="form-control input-sized" name="in_imap_folders[]" multiple>
|
||||
<option value="INBOX" selected="selected">INBOX</option>
|
||||
@foreach ($mailbox->getInImapFolders() as $imap_folder)
|
||||
<option value="{{ $imap_folder }}" selected="selected">{{ $imap_folder }}</option>
|
||||
@endforeach
|
||||
|
Loading…
Reference in New Issue
Block a user