From: Dessalines Date: Tue, 2 Feb 2021 17:18:18 +0000 (-0500) Subject: Fixing uri protected params getting clipped from cross posts. Fixes #141 X-Git-Url: http://these/git/%7B%60%24%7BwebArchiveUrl%7D/save/%24%7Bargs.pageFn.jump%20n%7D?a=commitdiff_plain;h=f9eeabb2f9963f9fbafd0c7fe0f2f5d9304975ef;p=lemmy-ui.git Fixing uri protected params getting clipped from cross posts. Fixes #141 --- diff --git a/src/shared/components/post-listing.tsx b/src/shared/components/post-listing.tsx index 41494c2..d75584b 100644 --- a/src/shared/components/post-listing.tsx +++ b/src/shared/components/post-listing.tsx @@ -1260,13 +1260,13 @@ export class PostListing extends Component { get crossPostParams(): string { let post = this.props.post_view.post; - let params = `?title=${post.name}`; + let params = `?title=${encodeURIComponent(post.name)}`; if (post.url) { params += `&url=${encodeURIComponent(post.url)}`; } if (post.body) { - params += `&body=${post.body}`; + params += `&body=${encodeURIComponent(post.body)}`; } return params; }