Skip to content

Commit

Permalink
Merge pull request #128 from NaikMegha/hotfix
Browse files Browse the repository at this point in the history
Fixing public link issue on page reload
  • Loading branch information
nfcampos authored Jan 18, 2024
2 parents 7e1e760 + 5b6c197 commit 4200fe1
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion frontend/src/components/Config.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,8 @@ function MultiOptionField(props: {
}

function PublicLink(props: { assistantId: string }) {
const link = window.location.href + "?shared_id=" + props.assistantId;
const currentLink = window.location.href;
const link = currentLink.includes('shared_id=') ? currentLink : currentLink + "?shared_id=" + props.assistantId;
return (
<div className="flex rounded-md shadow-sm mb-4">
<button
Expand Down

0 comments on commit 4200fe1

Please sign in to comment.