SMF Development > Fixed or Bogus Bugs

[4716] Remove Inactive Members bug.

(1/3) > >>

ethankcvds:
I've noticed over the past couple of days on my install of SMF 2.0 RC4 that Remove Inactive Members is removing people from the list that it should not be removing. For example some one registered today and I ran the the Remove Inactive Members with the activated their account after 30 days options it removes the act that just registered today from the list of members and those waiting for them to activate their account.

Similar to: http://www.simplemachines.org/community/index.php?topic=239823.msg1546396#msg1546396

michau:
I might have experienced similar problem, trying to reproduce it now - will post details as soon as I'm able to provide repetitive scenario.

In addition to that, I also run into out of memory problem when trying to run the clean up on around 14k members, where at least half should have been cleaned up. Cranking memory to 384MB directly in Subs-Members.php help for that.

Thx,
michau

emanuele:
If it helps, this can be solved by changing in ManageMaintenance.php

--- Code: (search) --- $where_vars = array(
'last_login' => $time_limit,
);
$where = 'mem.last_login < {int:last_login}';
if ($_POST['del_type'] == 'activated')
{
$where .= ' AND mem.is_activated = {int:is_activated}';
$where_vars['is_activated'] = 0;
}
--- End code ---


--- Code: (replace with) --- $where_vars = array(
'last_login' => $time_limit,
'date_registered' => $time_limit,
);
if ($_POST['del_type'] == 'activated')
{
$where = 'mem.date_registered < {int:date_registered} AND mem.is_activated = {int:is_activated}';
$where_vars['is_activated'] = 0;
} else {
$where = 'mem.last_login < {int:last_login}';
}
--- End code ---

ethankcvds:

--- Quote from: emanuele on May 06, 2011, 09:07:29 AM ---If it helps, this can be solved by changing in ManageMembers.php

--- Code: (search) --- $where_vars = array(
'last_login' => $time_limit,
);
$where = 'mem.last_login < {int:last_login}';
if ($_POST['del_type'] == 'activated')
{
$where .= ' AND mem.is_activated = {int:is_activated}';
$where_vars['is_activated'] = 0;
}
--- End code ---


--- Code: (replace with) --- $where_vars = array(
'last_login' => $time_limit,
'date_registered' => $time_limit,
);
if ($_POST['del_type'] == 'activated')
{
$where = 'mem.date_registered < {int:date_registered} AND mem.is_activated = {int:is_activated}';
$where_vars['is_activated'] = 0;
} else {
$where = 'mem.last_login < {int:last_login}';
}
--- End code ---

--- End quote ---

Fix's this issue. Also do note that the code you need to replace is in ManageMaintenance.php not ManageMembers.php

ethankcvds

emanuele:

--- Quote from: ethankcvds on May 08, 2011, 08:56:21 AM ---Also do note that the code you need to replace is in ManageMaintenance.php not ManageMembers.php

--- End quote ---
Right. :-[
I should stop doing two things at the same time, especially when the two files are named more or less the same... :P

Navigation

[0] Message Index

[#] Next page

Go to full version