From: Brion Vibber Date: Tue, 30 Nov 2010 20:46:33 +0000 (-0800) Subject: Flush router cache when saving Twitter admin settings: adding/removing keys can enabl... X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=b4fc54c308936477706acb5cc3c4acae4c3f3a4d;p=quix0rs-gnu-social.git Flush router cache when saving Twitter admin settings: adding/removing keys can enable/disable some actions. This avoids having users' Twitter settings unreachable after adding your keys to an installation with TwitterBridge on but not pre-configured. --- diff --git a/plugins/TwitterBridge/twitteradminpanel.php b/plugins/TwitterBridge/twitteradminpanel.php index d05a2c6b3e..1a83b47d56 100644 --- a/plugins/TwitterBridge/twitteradminpanel.php +++ b/plugins/TwitterBridge/twitteradminpanel.php @@ -133,6 +133,11 @@ class TwitteradminpanelAction extends AdminPanelAction $config->query('COMMIT'); + // Flush the router cache: we may have enabled/disabled bridging, + // which will add or remove some actions. + $cache = Cache::instance(); + $cache->delete(Router::cacheKey()); + return; }