Skip to content
Snippets Groups Projects
Commit e564c4b0 authored by Mariusz Trela's avatar Mariusz Trela
Browse files

A small fix in `delete_hive_post` SQL function

parent a691d643
No related branches found
No related tags found
No related merge requests found
This commit is part of merge request !400. Comments created here will be created in the context of that merge request.
......@@ -133,9 +133,11 @@ BEGIN
UPDATE hive_posts
SET counter_deleted =
(
SELECT max( counter_deleted ) + 1
FROM hive_posts
WHERE id = __post_id
SELECT max( hps.counter_deleted ) + 1
FROM hive_posts hps
INNER JOIN hive_accounts ha ON hps.author_id = ha.id
INNER JOIN hive_permlink_data hpd ON hps.permlink_id = hpd.id
WHERE ha.name = _author AND hpd.permlink = _permlink
)
,block_num = _block_num
WHERE id = __post_id;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment