Skip to content

Commit

Permalink
Fix: loop refresh when pathname is /- (erda-project#780)
Browse files Browse the repository at this point in the history
* docs: update README

* docs: fix format

* fix: auto format content by prettier

* chore: add changeLog section in pr template

* chore: remove duplicate pr template section

* fix: circular jump when location is /-
  • Loading branch information
daskyrk authored and erda-bot committed Jul 29, 2021
1 parent d4a3b30 commit 5a712f0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion shell/app/org-home/stores/org.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ const org = createStore({
}
}
if (currentOrg.name !== orgName) {
location.href = location.href.replace(`/${orgName}/`, `/${currentOrg.name}/`);
location.href = location.href.replace(`/${orgName}`, `/${currentOrg.name}`); // just replace the first match, which is org name
return;
}
if (orgId) {
Expand Down

0 comments on commit 5a712f0

Please # to comment.