RSS Feed/News generateEmailData does not reliably restore the original language

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
28,477
Points
823

Reputation:

The generateEmailData function doesn't wrap a try/finally around the handling of the setLanguage calls, meaning if the code inside this method throws an exception the global language may have changed unexpectedly.

This matters as by default job.php will execute multiple jobs via runJobInternal which may have the underlying language unexpectedly change. Maybe runJobInternal should restore the language to whatever was at the start and clear any visitor object to guard...

Read more

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