MantisBT: master-1.2.x 559ba4e4

Author Committer Branch Timestamp Parent
dregad dregad master-1.2.x 2014-12-09 06:23 master-1.2.x ad8c788e
Affected Issues  0017925: Order of notes in email notifications seem to be based on user who triggered the action
Changeset

New API current_user_set()

The function sets the $g_cache_current_user_id global variable, and
clears the user preferences cache ($g_cache_current_user_pref) if
necessary.

Using this new API to set the current user as opposed to working with
$g_cache_current_user_id makes sure we always get the correct data from
get_user_pref().

Resolves an issue where the order (as well as the number) of bugnotes in
email notifications is based on the user who triggered the action,
instead of the email's recipient.

Fixes 0017925

mod - core/authentication_api.php Diff File
mod - core/current_user_api.php Diff File
mod - core/email_api.php Diff File