diff options
author | Aleksander Machniak <alec@alec.pl> | 2014-03-14 14:17:23 +0100 |
---|---|---|
committer | Aleksander Machniak <alec@alec.pl> | 2014-03-14 14:17:23 +0100 |
commit | 9556f34d7501fd1613e0ad97a1b6adaebb3483f4 (patch) | |
tree | ae7ee2881b480719fc23f25e492cc70c7d04648b /plugins | |
parent | 53846f798f5257729efb4505812b3591b1971a39 (diff) |
Load password.js only when needed
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/password/password.php | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/plugins/password/password.php b/plugins/password/password.php index e31613ab1..83f951b98 100644 --- a/plugins/password/password.php +++ b/plugins/password/password.php @@ -70,9 +70,14 @@ class password extends rcube_plugin } $this->add_hook('settings_actions', array($this, 'settings_actions')); + $this->register_action('plugin.password', array($this, 'password_init')); $this->register_action('plugin.password-save', array($this, 'password_save')); - $this->include_script('password.js'); + + + if (strpos($rcmail->action, 'plugin.password') === 0) { + $this->include_script('password.js'); + } } function settings_actions($args) |