Fixed xf_user_profile.ignored inconsistency

Jake Bunce

Well-known member
Confirmed in 1.1.5

To reproduce, ignore a user and check your profile record. The ignored field will contain just the user_id and username of the ignored user. Now rebuild the user cache in the Admin CP. The ignored field will now contain the entire user record of the ignored user.

This is creating the following error when I rebuild the user cache and it processes a user with lots of ignored users:

Mysqli statement execute error : Data too long for column 'ignored' at row 1
 
For reference, it involves changing this line in library/XenForo/DataWriter/User.php:
Code:
$users = $this->_getUserIgnoreModel()->getIgnoredUsers($this->get('user_id'));
to:
Code:
$users = $this->_getUserIgnoreModel()->getUserIgnoreCache($this->get('user_id'));
The only effect I'm aware of is creating a template warning in debug mode only.
 
Top Bottom