mirror of
https://github.com/phpbb/phpbb.git
synced 2025-07-29 21:10:31 +02:00
Allow IP v4/v6 urls for remote avatars (Bug #11633) Delete avatar files automatically (Bug #11631) Automatically add selected columsn to group by statements in the converter (Bug #11465) git-svn-id: file:///svn/phpbb/trunk@7677 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
@@ -658,9 +658,15 @@ function delete_posts($where_type, $where_ids, $auto_sync = true, $posted_sync =
|
||||
{
|
||||
foreach ($post_counts as $poster_id => $substract)
|
||||
{
|
||||
$sql = 'UPDATE ' . USERS_TABLE . '
|
||||
SET user_posts = 0
|
||||
WHERE user_id = ' . $poster_id . '
|
||||
AND user_posts < ' . $substract;
|
||||
$db->sql_query($sql);
|
||||
$sql = 'UPDATE ' . USERS_TABLE . '
|
||||
SET user_posts = user_posts - ' . $substract . '
|
||||
WHERE user_id = ' . $poster_id;
|
||||
WHERE user_id = ' . $poster_id . '
|
||||
AND user_posts >= ' . $substract;
|
||||
$db->sql_query($sql);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user