]> Untitled Git - lemmy.git/commitdiff
Better urls.
authorDessalines <tyhou13@gmx.com>
Fri, 30 Aug 2019 04:41:41 +0000 (21:41 -0700)
committerDessalines <tyhou13@gmx.com>
Fri, 30 Aug 2019 04:41:41 +0000 (21:41 -0700)
ui/src/components/comment-form.tsx

index 57518a13eb0d8880ddfe475f7c3a00624fdf76e4..b4cc03a4a35c5488921a4632af23d826230f50ef 100644 (file)
@@ -47,7 +47,7 @@ export class CommentForm extends Component<CommentFormProps, CommentFormState> {
         {
           trigger: '@',
           selectTemplate: (item: any) => {
-            return `[/u/${item.original.key}](${window.location.origin}/u/${item.original.key})`;
+            return `[/u/${item.original.key}](/u/${item.original.key})`;
           },
           values: (text: string, cb: any) => {
             this.userSearch(text, users => cb(users));
@@ -59,7 +59,7 @@ export class CommentForm extends Component<CommentFormProps, CommentFormState> {
         {
           trigger: '#',
           selectTemplate: (item: any) => {
-            return `[/c/${item.original.key}](${window.location.origin}/c/${item.original.key})`;
+            return `[/c/${item.original.key}](/c/${item.original.key})`;
           },
           values: (text: string, cb: any) => {
             this.communitySearch(text, communities => cb(communities));