Fix restoring interval from local storage
Remove double initialization of interval in
createInitialDonationPaymentValues
where the value '0'
(coming from
the server when there is no URL parameter for the interval, i.e. user
started on the payment page) did overwrite the value from localStorage.
Adapt createInitialDonationPaymentValues
to return a null/undefined
value that will get ignored by the initializePayment
action the the
store.
This harmonizes the behavior of all payment fields into a common pattern, where the initial value comes from the following sources (in order of importance):
- localStorage
- URL parameter
- Initial value in
index.ts
of store