Project

General

Profile

Actions

Bug #4786

closed

Warning JUser: :_load: Unable to load user with ID: --- when deleting user from CB 2.0 User Management

Added by nant about 10 years ago. Updated about 10 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Target version:
Start date:
22 October 2014
Due date:
% Done:

100%

Estimated time:

Description

With latest CB 2.0 nightly build if I go to CB User Management page and select a user to delete I see the message:

Warning
JUser: :_load: Unable to load user with ID: 804

right before the success message.

See attached screenshot.


Files

2014-10-22_10-36-22.png (141 KB) 2014-10-22_10-36-22.png nant, 22 October 2014 09:39
Actions #1

Updated by nant about 10 years ago

Happens on both J33 and J25

Actions #2

Updated by beat about 10 years ago

Bug is in CB Blogs in event onAfterDeleteUser: It tries to load that user after it has been deleted:

onAfterDeleteUser calls function deleteBlogs which calls function getBlogs with $user and $viewer being the deleted CB UserTable $user which has this line:

.    ( ( ! Application::User( (int) $viewer->get( 'id' ) )->isGlobalModerator() ) && ( $viewer->get( 'id' ) != $user->get( 'id' ) ) ? ...

Inverting the two like this:

.    ( ( $viewer->get( 'id' ) != $user->get( 'id' ) ) && ( ! Application::User( (int) $viewer->get( 'id' ) )->isGlobalModerator() )? ...

fixes this.

Actions #3

Updated by beat about 10 years ago

In short: CB Blogs event handler onAfterDeleteUser was trying to load the just deleted user.

Fixing.

Actions #4

Updated by beat about 10 years ago

  • Status changed from Assigned to Resolved
  • Assignee changed from krileon to beat
  • % Done changed from 0 to 100

Fixed in MR !622

Actions #5

Updated by beat about 10 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF