From fd23fcee14762e6e8265a95c6f096746ebbaaaf0 Mon Sep 17 00:00:00 2001 From: Eduard Heimbuch Date: Wed, 15 Jan 2020 09:09:54 +0100 Subject: [PATCH] dont redirect to default branch on changesets view --- scm-ui/ui-webapp/src/repos/containers/ChangesetsRoot.tsx | 8 -------- 1 file changed, 8 deletions(-) diff --git a/scm-ui/ui-webapp/src/repos/containers/ChangesetsRoot.tsx b/scm-ui/ui-webapp/src/repos/containers/ChangesetsRoot.tsx index c18be2409a..d86022925e 100644 --- a/scm-ui/ui-webapp/src/repos/containers/ChangesetsRoot.tsx +++ b/scm-ui/ui-webapp/src/repos/containers/ChangesetsRoot.tsx @@ -15,14 +15,6 @@ type Props = WithTranslation & }; class ChangesetsRoot extends React.Component { - componentDidMount() { - const { branches, baseUrl } = this.props; - if (branches?.length > 0 && this.isSelectedBranchNotABranch()) { - const defaultBranch = branches?.filter(b => b.defaultBranch === true)[0]; - this.props.history.replace(`${baseUrl}/branch/${encodeURIComponent(defaultBranch.name)}/changesets/`); - } - } - stripEndingSlash = (url: string) => { if (url.endsWith("/")) { return url.substring(0, url.length - 1);