RSS Feed/News Add-on controls unnecessarily load complete template records

Status
Not open for further replies.

ENXF NET

Administrator
Staff member
Administrator
Moderator
+Lifetime VIP+
S.V.I.P.S Member
S.V.I.P Member
V.I.P Member
Collaborate
Registered
Joined
Nov 13, 2018
Messages
34,051
Points
823

Reputation:

Opening an add-on’s controls menu calls XF\Admin\Controller\AddOnController::actionControls(), which executes:
Code:

Code:
		$templates = $this->finder(TemplateFinder::class)
			->where('addon_id', $addOn->addon_id)
			->fetch()
			->groupBy('type');
SQL:

Code:
SELECT *
FROM xf_template
WHERE addon_id = 'OzzModz/KnowledgeBase';
All matching templates including template and template_parsed are loaded only to determine whether public/ email /admin templates exist

On large installations query can...

Read more

Continue reading...
 
Status
Not open for further replies.
Top