mirror of
https://git.joinplu.me/Plume/Plume.git
synced 2025-03-14 02:52:41 +00:00
Fix links for post from remote blogs
This commit is contained in:
parent
b7aa1790e5
commit
15477875da
1 changed files with 2 additions and 2 deletions
|
@ -206,14 +206,14 @@ impl Post {
|
|||
json!({
|
||||
"post": self,
|
||||
"author": self.get_authors(conn)[0].to_json(conn),
|
||||
"url": format!("/~/{}/{}/", blog.actor_id, self.slug),
|
||||
"url": format!("/~/{}/{}/", blog.get_fqn(conn), self.slug),
|
||||
"date": self.creation_date.timestamp(),
|
||||
"blog": blog.to_json(conn)
|
||||
})
|
||||
}
|
||||
|
||||
pub fn compute_id(&self, conn: &PgConnection) -> String {
|
||||
ap_url(format!("{}/~/{}/{}/", BASE_URL.as_str(), self.get_blog(conn).actor_id, self.slug))
|
||||
ap_url(format!("{}/~/{}/{}/", BASE_URL.as_str(), self.get_blog(conn).get_fqn(conn), self.slug))
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue