Changeset 2698 in subversion


Ignore:
Timestamp:
Jul 2, 2009 4:35:45 AM (4 years ago)
Author:
thomasb
Message:

Create rcube_user instance early to enable the following plugin hooks to use it

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/roundcubemail/program/include/rcube_user.php

    r2692 r2698  
    387387    if ($user_id = $dbh->insert_id(get_sequence_name('users'))) 
    388388    { 
     389      // create rcube_user instance to make plugin hooks work 
     390      $user_instance = new rcube_user($user_id); 
     391      $rcmail->user = $user_instance; 
     392 
    389393      $mail_domain = $rcmail->config->mail_domain($host); 
    390394 
     
    450454    } 
    451455     
    452     return $user_id ? new rcube_user($user_id) : false; 
     456    return $user_id ? $user_instance : false; 
    453457  } 
    454458   
Note: See TracChangeset for help on using the changeset viewer.