Commit 002a503f authored by Côme Chilliet's avatar Côme Chilliet
Browse files

Fixes #4954 Reseting mail server cache when it makes sense

parent 4fb00add
......@@ -112,9 +112,17 @@ class serviceCyrus extends simpleService
);
}
function save()
protected function post_save()
{
parent::save();
parent::post_save();
if (!$this->initially_was_account) {
mailMethod::resetMailServersCache();
}
}
protected function post_remove ()
{
parent::post_remove();
mailMethod::resetMailServersCache();
}
}
......
......@@ -103,9 +103,17 @@ class serviceDovecot extends simpleService
);
}
function save()
protected function post_save()
{
parent::save();
parent::post_save();
if (!$this->initially_was_account) {
mailMethod::resetMailServersCache();
}
}
protected function post_remove ()
{
parent::post_remove();
mailMethod::resetMailServersCache();
}
}
......
......@@ -23,7 +23,7 @@
class serviceIMAP extends simpleService
{
/* This plugin only writes its objectClass */
var $objectclasses = array("fdImapServer");
var $objectclasses = array('fdImapServer');
/* Return plugin informations for acl handling */
static function plInfo()
......@@ -42,14 +42,26 @@ class serviceIMAP extends simpleService
*/
static function getAttributesInfo ()
{
return array ();
return array();
}
function execute()
{
return "<b>This server runs an IMAP or POP3 server</b>".parent::execute();
return '<b>This server runs an IMAP or POP3 server</b>'.parent::execute();
}
}
protected function post_save()
{
parent::post_save();
if (!$this->initially_was_account) {
mailMethod::resetMailServersCache();
}
}
protected function post_remove ()
{
parent::post_remove();
mailMethod::resetMailServersCache();
}
}
?>
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment