Skip to content

Commit

Permalink
Move app history replace to happen only if not in plugin legacy mode (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
mgdelacroix committed Oct 6, 2021
1 parent a434056 commit 5264b19
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions webapp/src/app.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -96,11 +96,14 @@ const App = React.memo((): JSX.Element => {
dispatch(fetchLanguage())
dispatch(fetchMe())
dispatch(fetchClientConfig())
if (Utils.isFocalboardPlugin()) {
history.replace(window.location.pathname.replace((window as any).frontendBaseURL, ''))
}
}, [])

if (Utils.isFocalboardPlugin()) {
useEffect(() => {
history.replace(window.location.pathname.replace((window as any).frontendBaseURL, ''))
}, [])
}

if (!inPluginLegacy) {
useEffect(() => {
wsClient.open()
Expand Down

0 comments on commit 5264b19

Please sign in to comment.