Correctly encode the path for query string

This commit is contained in:
David Granado 2022-01-21 21:39:51 -06:00 committed by Thomas Zarebczan
parent 04aa77253f
commit a417cc3aca

View file

@ -108,7 +108,7 @@ function FileActions(props: Props) {
push(`/$/${PAGES.CHANNEL_NEW}?redirect=${pathname}`); push(`/$/${PAGES.CHANNEL_NEW}?redirect=${pathname}`);
doToast({ message: __('A channel is required to repost on %SITE_NAME%', { SITE_NAME }) }); doToast({ message: __('A channel is required to repost on %SITE_NAME%', { SITE_NAME }) });
} else { } else {
push(`/$/${PAGES.REPOST_NEW}?from=${encodeURIComponent(uri)}&redirect=${pathname}`); push(`/$/${PAGES.REPOST_NEW}?from=${encodeURIComponent(uri)}&redirect=${encodeURIComponent(pathname)}`);
} }
} }