Commit 9108a7a
authored
fix: Add query check to swap state and reset to origin (#12456)
<!--
Before opening a pull request, please read the [contributing
guidelines](https://github.com/pancakeswap/pancake-frontend/blob/develop/CONTRIBUTING.md)
first
-->
<!-- start pr-codex -->
---
## PR-Codex overview
This PR focuses on updating the `handleOnClick` function in the
`SentryErrorBoundary` component across two files to reload the current
page using the `origin` of the window location. Additionally, it
modifies the logic for determining `inputChainId` and `outputChainId` in
the `hooks.ts` file.
### Detailed summary
- In `apps/web/src/components/ErrorBoundary/SentryErrorBoundary.tsx`:
- Updated `handleOnClick` to reload the page using `window.location.href
= origin`.
- In `apps/solana/src/components/SentryErrorBoundary.tsx`:
- Updated `handleOnClick` similarly to reload the page using
`window.location.href = origin`.
- In `apps/web/src/state/swap/hooks.ts`:
- Removed duplicate import of `NonEVMChainId` and `UnifiedChainId`.
- Updated logic for `inputChainId` and `outputChainId` to exclude
`Aptos` chains.
> ✨ Ask PR-Codex anything about this PR by commenting with `/codex {your
question}`
<!-- end pr-codex -->1 parent 76d29a4 commit 9108a7a
File tree
3 files changed
+13
-5
lines changed- apps
- solana/src/components
- web/src
- components/ErrorBoundary
- state/swap
3 files changed
+13
-5
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
9 | | - | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
10 | 13 | | |
11 | 14 | | |
12 | 15 | | |
| |||
Lines changed: 4 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
9 | | - | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
10 | 13 | | |
11 | 14 | | |
12 | 15 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
| 4 | + | |
4 | 5 | | |
5 | 6 | | |
6 | 7 | | |
| |||
14 | 15 | | |
15 | 16 | | |
16 | 17 | | |
17 | | - | |
18 | 18 | | |
19 | 19 | | |
20 | 20 | | |
| |||
82 | 82 | | |
83 | 83 | | |
84 | 84 | | |
85 | | - | |
86 | | - | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
87 | 89 | | |
88 | 90 | | |
89 | 91 | | |
| |||
0 commit comments