mirror of
https://github.com/LemmyNet/lemmy.git
synced 2024-11-22 04:11:17 +00:00
Remove controversial migration, let admins run in manually
This commit is contained in:
parent
cdc1cf3bf7
commit
47e84b274c
2 changed files with 0 additions and 34 deletions
|
@ -1,17 +0,0 @@
|
|||
UPDATE
|
||||
post_aggregates
|
||||
SET
|
||||
controversy_rank = CASE WHEN downvotes <= 0
|
||||
OR upvotes <= 0 THEN
|
||||
0
|
||||
ELSE
|
||||
(upvotes + downvotes) * CASE WHEN upvotes > downvotes THEN
|
||||
downvotes::float / upvotes::float
|
||||
ELSE
|
||||
upvotes::float / downvotes::float
|
||||
END
|
||||
END
|
||||
WHERE
|
||||
upvotes > 0
|
||||
AND downvotes > 0;
|
||||
|
|
@ -1,17 +0,0 @@
|
|||
UPDATE
|
||||
post_aggregates
|
||||
SET
|
||||
controversy_rank = CASE WHEN downvotes <= 0
|
||||
OR upvotes <= 0 THEN
|
||||
0
|
||||
ELSE
|
||||
(upvotes + downvotes) ^ CASE WHEN upvotes > downvotes THEN
|
||||
downvotes::float / upvotes::float
|
||||
ELSE
|
||||
upvotes::float / downvotes::float
|
||||
END
|
||||
END
|
||||
WHERE
|
||||
upvotes > 0
|
||||
AND downvotes > 0;
|
||||
|
Loading…
Reference in a new issue