Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- class CDefaultValuesPlugin extends AApiPlugin
- {
- /**
- * @param CApiPluginManager $oPluginManager
- */
- public function __construct(CApiPluginManager $oPluginManager)
- {
- parent::__construct('1.0', $oPluginManager);
- $this->AddHook('api-account-construct', 'PluginApiAccountConstruct');
- }
- /**
- * @param CAccount $oAccount
- */
- public function PluginApiAccountConstruct(&$oAccount)
- {
- if (is_a($oAccount, 'CAccount'))
- {
- $oAccount->MailMode =
- EAccountMailMode::KeepMessagesOnServerAndDeleteMessageWhenItsRemovedFromTrash;
- }
- }
- }
- return new CDefaultValuesPlugin($this);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement