@autobusal/order-process 1.3.5 → 1.3.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/Standard/Standard.tsx +17 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 1.3.6
|
|
4
|
+
|
|
5
|
+
### Fixed
|
|
6
|
+
|
|
7
|
+
- **A 200 with an empty body no longer navigates to the homepage** while the order sits reserved - the confirmation path is only followed when the API actually named one. (Audit BOOK-04-b.)
|
|
8
|
+
|
|
3
9
|
## 1.3.5
|
|
4
10
|
|
|
5
11
|
### Fixed
|
package/Standard/Standard.tsx
CHANGED
|
@@ -37,10 +37,26 @@ const Standard = ({ type, hash, t }: Props): JSX.Element => {
|
|
|
37
37
|
}
|
|
38
38
|
}, [isError, error, navigate, t]);
|
|
39
39
|
|
|
40
|
-
|
|
40
|
+
/*
|
|
41
|
+
* Claude - 2026-08-22 (audit finding BOOK-04-b): a 200 whose body is
|
|
42
|
+
* empty or not the expected path string used to make this
|
|
43
|
+
* <Navigate to=""> - which lands on the HOMEPAGE while the order sits
|
|
44
|
+
* reserved, silently. Measured once in the audit (an intermittent BFF
|
|
45
|
+
* hiccup); never navigate anywhere that isn't the confirmation the API
|
|
46
|
+
* actually named.
|
|
47
|
+
*/
|
|
48
|
+
if (isSuccess && typeof data === 'string' && data.startsWith('/')) {
|
|
41
49
|
return <Navigate to={ data } />;
|
|
42
50
|
}
|
|
43
51
|
|
|
52
|
+
if (isSuccess) {
|
|
53
|
+
return (
|
|
54
|
+
<Container>
|
|
55
|
+
<Inline text={ t('order_process.error', { ns: 'common', defaultValue: 'We could not confirm your order. Please open your orders to check its state.' }) } />
|
|
56
|
+
</Container>
|
|
57
|
+
);
|
|
58
|
+
}
|
|
59
|
+
|
|
44
60
|
return (
|
|
45
61
|
<Container>
|
|
46
62
|
<Inline text={ t('order_process.loading') } />
|