Problem
MyAccountPageViewModel now prefers ApplicationCache.GetMerchantDetails() over fetching fresh merchant details from the API.
Impact
Merchant details are not cleared on logout, so a user who logs out and then logs in as a different merchant can see the previous merchant's name/details in My Account until the cache is refreshed elsewhere.
Reproduction
- Log in as merchant A.
- Open My Account so merchant details are cached.
- Log out.
- Log in as merchant B.
- Open My Account.
Expected
My Account should show merchant B's details.
Actual
Cached details from merchant A can be reused.
Suggested fix
Clear cached merchant details on logout, or scope the cached value to the active session/merchant and always refresh when the session changes.
Problem
MyAccountPageViewModelnow prefersApplicationCache.GetMerchantDetails()over fetching fresh merchant details from the API.Impact
Merchant details are not cleared on logout, so a user who logs out and then logs in as a different merchant can see the previous merchant's name/details in My Account until the cache is refreshed elsewhere.
Reproduction
Expected
My Account should show merchant B's details.
Actual
Cached details from merchant A can be reused.
Suggested fix
Clear cached merchant details on logout, or scope the cached value to the active session/merchant and always refresh when the session changes.