Closed (fixed)
Project:
Flag
Version:
6.x-1.1
Component:
Flag core
Priority:
Normal
Category:
Bug report
Assigned:
Reporter:
Created:
18 Jun 2009 at 17:22 UTC
Updated:
29 Sep 2009 at 00:00 UTC
Jump to comment: Most recent file
Hi,
The Flag 6.x (maybe 5.x too) doesn't decrease the counts on user deletion. My little patch fixes this.
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | flag_user_delete_counter2.patch | 1.04 KB | quicksketch |
| #1 | flag_user_delete_counter.patch | 956 bytes | quicksketch |
| flag6_user_delete_counter.patch | 1.46 KB | aries |
Comments
Comment #1
quicksketchThanks, the patch works great except for a small type where "$flag_data->counter--" should be "$flag_data->count--". I cleaned up the code to match the code style in the rest of Flag (SQL queries are one line, no abbreviations for variable names). I've committed the attached patch for all versions of Flag.
Comment #2
quicksketchOops, and a small followup to make the query join on both content_id and content_type, otherwise we'd only be updating users OR nodes OR comments for a particular content_id. Also committed.