Page MenuHomePhabricator

raw-paste-data.txt

Authored By
stwalkerster
Oct 16 2020, 12:20 PM
Size
1 KB
Referenced Files
None
Subscribers
None

raw-paste-data.txt

-- duplicate the "removed private information" row into a comment log entry for the requester comment.
insert into log
select null id, c.id objectid, 'Comment' objecttype, l.user, 'EditComment-c' action, l.timestamp, null comment, 0 updateversion
from log l
inner join request r on l.objectid = r.id and l.objecttype = 'Request'
inner join comment c on r.id = c.request
where l.action in ('Removed private information via database')
and c.visibility = 'requester';
-- change the existing "remove private information" log entries to the correct action for the request log
update log l set action = 'EditComment-r' where l.action in ('Removed private information via database');
-- add a comment on the requests for the discarded requests
insert into comment select null, l.timestamp, l.user, l.action, 'user', l.objectid, 0 from log l where action = 'Discarded as likely a spambot';
-- change the log action to a drop for the discarded requests
update log set action = 'Closed 0' where action = 'Discarded as likely a spambot';

File Metadata

Mime Type
text/plain; charset=utf-8
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
244013
Default Alt Text
raw-paste-data.txt (1 KB)

Event Timeline