|
|
|
@ -562,11 +562,20 @@ class rcube_sieve_vacation extends rcube_sieve_engine
|
|
|
|
|
$this->script_name = 'roundcube';
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
$this->script = array($rule);
|
|
|
|
|
$script_active = false;
|
|
|
|
|
// use default script contents
|
|
|
|
|
if (!$this->rc->config->get('managesieve_kolab_master')) {
|
|
|
|
|
$script_file = $this->rc->config->get('managesieve_default');
|
|
|
|
|
if ($script_file && is_readable($script_file)) {
|
|
|
|
|
$content = file_get_contents($script_file);
|
|
|
|
|
}
|
|
|
|
|
// if script exists
|
|
|
|
|
else {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// create and load script
|
|
|
|
|
if ($this->sieve->save_script($this->script_name, $content)) {
|
|
|
|
|
$this->sieve->load($this->script_name);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
$script_active = in_array($this->script_name, $this->active);
|
|
|
|
|
|
|
|
|
|
// re-order rules if needed
|
|
|
|
@ -616,6 +625,9 @@ class rcube_sieve_vacation extends rcube_sieve_engine
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (!$this->sieve->script) {
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
$this->sieve->script->content = $this->script;
|
|
|
|
|