From 01b8dcf136e5910ab8fa98b12cdea6cb0fc4309c Mon Sep 17 00:00:00 2001 From: "Nicholas K. Dionysopoulos" Date: Thu, 25 Aug 2016 13:23:03 +0300 Subject: [PATCH] Load language files on callback event IMHO JPlugin should be doing that automatically when the plugin object is instantiated. Since it doesn't developers end up calling loadLangauge on every event handler, making performance worse overall. Oh, well, that's the subject of another PR... --- plugins/authentication/facebook/facebook.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/plugins/authentication/facebook/facebook.php b/plugins/authentication/facebook/facebook.php index 9ddccba8ef098..29026f809dbd9 100644 --- a/plugins/authentication/facebook/facebook.php +++ b/plugins/authentication/facebook/facebook.php @@ -81,6 +81,9 @@ public function onUserLoginFormFields() public function onAjaxFacebook() { + // Load plugin language + $this->loadLanguage('plg_authentication_facebook'); + // Try to exchange the code with a token $facebookOauth = $this->getFacebookOauth(); $app = JFactory::getApplication();