58 lines
1.7 KiB
Plaintext
58 lines
1.7 KiB
Plaintext
{
|
|
use esmith::ConfigDB;
|
|
my $cdb = esmith::ConfigDB->open() || die "Couldn't open ConfigDB\n";
|
|
##Added for version smeserver-roundcube-1.1-4
|
|
my $plugins = $cdb->get_prop('roundcube','PluginsList') || '';
|
|
|
|
return unless ($plugins ne '');
|
|
|
|
#nextcloud_attachements is used
|
|
if ($plugins !~ 'nextcloud_attachments')
|
|
{
|
|
$plugins = $plugins.',nextcloud_attachments';
|
|
$cdb->set_prop('roundcube','PluginsList',"$plugins");
|
|
}
|
|
#sieverule is now used instead of
|
|
if ($plugins !~ 'managesieve')
|
|
{
|
|
$plugins = $plugins.',managesieve';
|
|
$cdb->set_prop('roundcube','PluginsList',"$plugins");
|
|
}
|
|
# sieverule deprecated
|
|
if ($plugins =~ 'sieverule')
|
|
{
|
|
$plugins =~ s/,sieverule//g;
|
|
$cdb->set_prop('roundcube','PluginsList',"$plugins");
|
|
}
|
|
# markasjunk2 deprecated
|
|
if ($plugins =~ 'markasjunk')
|
|
{
|
|
$plugins =~ s/markasjunk2/markasjunk/g;
|
|
$cdb->set_prop('roundcube','PluginsList',"$plugins");
|
|
}
|
|
#Carddav is a really bad plugin, when available it will become usefull
|
|
if ($plugins =~ 'carddav')
|
|
{
|
|
$plugins =~ s/,carddav//g;
|
|
$cdb->set_prop('roundcube','PluginsList',"$plugins");
|
|
}
|
|
#remove calendar
|
|
if ($plugins =~ 'calendar')
|
|
{
|
|
$plugins =~ s/,calendar//g;
|
|
$cdb->set_prop('roundcube','PluginsList',"$plugins");
|
|
}
|
|
#remove libcalendaring
|
|
if ($plugins =~ 'libcalendaring')
|
|
{
|
|
$plugins =~ s/,libcalendaring//g;
|
|
$cdb->set_prop('roundcube','PluginsList',"$plugins");
|
|
}
|
|
#remove tasklist
|
|
if ($plugins =~ 'tasklist')
|
|
{
|
|
$plugins =~ s/,tasklist//g;
|
|
$cdb->set_prop('roundcube','PluginsList',"$plugins");
|
|
}
|
|
}
|