Don't load plugin pages if plugin is not enabled. Thanks to Niels Teusink for findin...
authorpdontthink <pdontthink@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Fri, 5 Dec 2008 09:46:53 +0000 (09:46 +0000)
committerpdontthink <pdontthink@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Fri, 5 Dec 2008 09:46:53 +0000 (09:46 +0000)
git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@13354 7612ce4b-ef26-0410-bec9-ea0150e637f0

plugins/mail_fetch/fetch.php
plugins/mail_fetch/options.php

index d7085276eeef8f50480e853729715190dffbb269..dbaf9740856e081ee903d035ec99ae811a103556 100644 (file)
@@ -20,6 +20,11 @@ require('../../include/init.php');
 include_once(SM_PATH . 'functions/imap_general.php');
 include_once(SM_PATH . 'plugins/mail_fetch/functions.php' );
 
+// don't load this page if this plugin is not enabled
+//
+global $plugins;
+if (!in_array('mail_fetch', $plugins)) exit;
+
 /* globals */
 sqgetGlobalVar('delimiter',  $delimiter,  SQ_SESSION);
 /* end globals */
index 35eb094e0e6e6ad7b8cc5e185a2fd138145f80fa..e74766f4cb119ee1d9d9f3f111e9da48d24de13e 100644 (file)
@@ -20,6 +20,11 @@ include_once(SM_PATH . 'plugins/mail_fetch/functions.php' );
 include_once(SM_PATH . 'functions/imap_general.php');
 include_once(SM_PATH . 'functions/forms.php');
 
+// don't load this page if this plugin is not enabled
+//
+global $plugins;
+if (!in_array('mail_fetch', $plugins)) exit;
+
 /* globals */
 sqgetGlobalVar('delimiter',  $delimiter,  SQ_SESSION);