mirror of
https://github.com/LemmyNet/lemmy.git
synced 2024-11-30 00:01:25 +00:00
Cleaning up mod action line.
This commit is contained in:
parent
40e966246f
commit
e42b75f6dc
1 changed files with 2 additions and 3 deletions
|
@ -212,9 +212,8 @@ impl Object for ApubPost {
|
|||
let first_attachment = page.attachment.first();
|
||||
|
||||
let form = if !page.is_mod_action(context).await? {
|
||||
let first_attachment_url = first_attachment.cloned().map(Attachment::url);
|
||||
let url = if first_attachment.is_some() {
|
||||
first_attachment_url
|
||||
let url = if let Some(attachment) = first_attachment.cloned() {
|
||||
Some(attachment.url())
|
||||
} else if page.kind == PageType::Video {
|
||||
// we cant display videos directly, so insert a link to external video page
|
||||
Some(page.id.inner().clone())
|
||||
|
|
Loading…
Reference in a new issue