Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Display deleted or removed comments when they have children #3965

Merged
merged 14 commits into from
Sep 24, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 12 additions & 12 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

24 changes: 12 additions & 12 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[workspace.package]
version = "0.18.1"
version = "0.18.4"
edition = "2021"
description = "A link aggregator for the fediverse"
license = "AGPL-3.0"
Expand Down Expand Up @@ -58,16 +58,16 @@ members = [
]

[workspace.dependencies]
lemmy_api = { version = "=0.18.1", path = "./crates/api" }
lemmy_api_crud = { version = "=0.18.1", path = "./crates/api_crud" }
lemmy_apub = { version = "=0.18.1", path = "./crates/apub" }
lemmy_utils = { version = "=0.18.1", path = "./crates/utils" }
lemmy_db_schema = { version = "=0.18.1", path = "./crates/db_schema" }
lemmy_api_common = { version = "=0.18.1", path = "./crates/api_common" }
lemmy_routes = { version = "=0.18.1", path = "./crates/routes" }
lemmy_db_views = { version = "=0.18.1", path = "./crates/db_views" }
lemmy_db_views_actor = { version = "=0.18.1", path = "./crates/db_views_actor" }
lemmy_db_views_moderator = { version = "=0.18.1", path = "./crates/db_views_moderator" }
lemmy_api = { version = "=0.18.4", path = "./crates/api" }
lemmy_api_crud = { version = "=0.18.4", path = "./crates/api_crud" }
lemmy_apub = { version = "=0.18.4", path = "./crates/apub" }
lemmy_utils = { version = "=0.18.4", path = "./crates/utils" }
lemmy_db_schema = { version = "=0.18.4", path = "./crates/db_schema" }
lemmy_api_common = { version = "=0.18.4", path = "./crates/api_common" }
lemmy_routes = { version = "=0.18.4", path = "./crates/routes" }
lemmy_db_views = { version = "=0.18.4", path = "./crates/db_views" }
lemmy_db_views_actor = { version = "=0.18.4", path = "./crates/db_views_actor" }
lemmy_db_views_moderator = { version = "=0.18.4", path = "./crates/db_views_moderator" }
activitypub_federation = { version = "0.5.0-beta.3", default-features = false, features = [
"actix-web",
] }
Expand Down Expand Up @@ -168,4 +168,4 @@ prometheus = { version = "0.13.3", features = ["process"], optional = true }
actix-web-prom = { version = "0.6.0", optional = true }
serial_test = { workspace = true }
clap = { version = "4.3.19", features = ["derive"] }
lemmy_federate = { version = "0.18.1", path = "crates/federate" }
lemmy_federate = { version = "0.18.4", path = "crates/federate" }
15 changes: 0 additions & 15 deletions crates/db_views/src/comment_view.rs
Original file line number Diff line number Diff line change
Expand Up @@ -198,21 +198,6 @@ fn queries<'a>() -> Queries<
query = query.filter(comment_like::score.eq(-1));
}

let is_creator = options.creator_id == options.local_user.map(|l| l.person.id);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good. I'm sure these just got copy-pasted from the post_view ones, where it does make sense to have them.

// only show deleted comments to creator
if !is_creator {
query = query.filter(comment::deleted.eq(false));
}

let is_admin = options
.local_user
.map(|l| l.local_user.admin)
.unwrap_or(false);
// only show removed comments to admin when viewing user profile
if !(options.is_profile_view && is_admin) {
query = query.filter(comment::removed.eq(false));
}

if !options
.local_user
.map(|l| l.local_user.show_bot_accounts)
Expand Down
2 changes: 1 addition & 1 deletion crates/utils/translations
Submodule translations updated 90 files
+9 −0 .woodpecker.yml
+4 −2 README.md
+3 −0 email/af.json
+27 −0 email/ar.json
+27 −0 email/bg.json
+17 −0 email/cs.json
+27 −0 email/da.json
+27 −0 email/de.json
+27 −0 email/el.json
+5 −3 email/en.json
+27 −0 email/eo.json
+27 −0 email/es.json
+23 −0 email/et.json
+18 −0 email/eu.json
+12 −6 email/fi.json
+27 −0 email/fr.json
+27 −0 email/gl.json
+8 −0 email/hi.json
+19 −0 email/hu.json
+27 −0 email/id.json
+20 −6 email/it.json
+27 −0 email/ja.json
+16 −16 email/ko.json
+27 −0 email/nl.json
+27 −0 email/nn.json
+18 −0 email/oc.json
+26 −0 email/pl.json
+16 −7 email/pt.json
+27 −0 email/pt_BR.json
+27 −0 email/ro.json
+27 −0 email/ru.json
+24 −0 email/sk.json
+1 −0 email/th.json
+27 −0 email/tr.json
+27 −0 email/uk.json
+10 −0 email/zh_Hans.json
+18 −0 email/zh_Hant.json
+129 −13 translations/ar.json
+78 −78 translations/as.json
+189 −56 translations/bg.json
+7 −1 translations/bn.json
+191 −10 translations/ca.json
+35 −6 translations/cs.json
+28 −28 translations/cy.json
+401 −156 translations/da.json
+242 −83 translations/de.json
+136 −24 translations/el.json
+526 −475 translations/en.json
+204 −23 translations/eo.json
+122 −10 translations/es.json
+442 −0 translations/et.json
+87 −25 translations/eu.json
+150 −24 translations/fa.json
+177 −81 translations/fi.json
+166 −18 translations/fr.json
+2 −7 translations/ga.json
+83 −12 translations/gl.json
+35 −35 translations/got.json
+163 −0 translations/he.json
+31 −8 translations/hi.json
+16 −8 translations/hu.json
+156 −35 translations/id.json
+137 −32 translations/it.json
+172 −54 translations/ja.json
+0 −2 translations/ka.json
+3 −4 translations/ko.json
+248 −19 translations/lt.json
+50 −0 translations/lv.json
+2 −4 translations/ml.json
+2 −2 translations/mnc.json
+123 −5 translations/nb_NO.json
+218 −85 translations/nl.json
+528 −0 translations/nn.json
+2 −4 translations/oc.json
+95 −18 translations/pl.json
+138 −28 translations/pt.json
+109 −37 translations/pt_BR.json
+547 −0 translations/ro.json
+133 −10 translations/ru.json
+503 −24 translations/sk.json
+2 −4 translations/sq.json
+6 −1 translations/sr_Latn.json
+23 −5 translations/sv.json
+80 −6 translations/th.json
+408 −134 translations/tr.json
+402 −180 translations/uk.json
+2 −3 translations/vi.json
+43 −10 translations/zh.json
+2 −3 translations/zh_Hant.json
+140 −140 translators.json
4 changes: 2 additions & 2 deletions docker/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ services:

lemmy:
# use "image" to pull down an already compiled lemmy. make sure to comment out "build".
# image: dessalines/lemmy:0.18.1
# image: dessalines/lemmy:0.18.4
# platform: linux/x86_64 # no arm64 support. uncomment platform if using m1.
# use "build" to build your local lemmy server image for development. make sure to comment out "image".
# run: docker compose up --build
Expand Down Expand Up @@ -55,7 +55,7 @@ services:

lemmy-ui:
# use "image" to pull down an already compiled lemmy-ui. make sure to comment out "build".
image: dessalines/lemmy-ui:0.18.1
image: dessalines/lemmy-ui:0.18.4
# platform: linux/x86_64 # no arm64 support. uncomment platform if using m1.
# use "build" to build your local lemmy ui image for development. make sure to comment out "image".
# run: docker compose up --build
Expand Down