mirror of
https://github.com/oceanprotocol/market.git
synced 2024-12-02 05:57:29 +01:00
fix reset pricing on tx execution
This commit is contained in:
parent
f8a6edc3c6
commit
245ccfe5e4
@ -30,9 +30,10 @@ export function Steps({
|
|||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (!chainId) return
|
if (!chainId) return
|
||||||
|
|
||||||
// Reset the pricing values on chainId change
|
// Reset the pricing values on chainId change:
|
||||||
// the user needs to update the pricing schema on network changes
|
// - the user needs to update the pricing schema on network changes
|
||||||
if (values.pricing.price) {
|
// - if the tx has been started, don't restore pricing values
|
||||||
|
if (values.pricing.price && values.feedback[1].status === 'pending') {
|
||||||
setFieldValue('pricing', initialValues.pricing)
|
setFieldValue('pricing', initialValues.pricing)
|
||||||
router.push(`/publish/3`)
|
router.push(`/publish/3`)
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user