Bug: Entering an address into the location field and hitting ‘return' quickly breaks search #2129
Labels
dev
Code Development
Priority - Low
Optional: Recommended if time permits
Release Note: Bug
Something isn't working (Shows on release notes under "Bug Fixes")
Milestone
Describe the bug
On the landing page and on the map screen, if you type in or paste an address and hit return (submit form) before the autocomplete appears, the search fails and user incorrectly gets “Sorry, we don’t have any results for this area”. Also note that the location field is blank again — ideally we should leave what they typed in the field, or display it in the error.
![image](https://private-user-images.githubusercontent.com/3376957/324346074-7f3a1b2b-73ad-40fe-b3cd-aa33a390a693.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjQzMzAwMzgsIm5iZiI6MTcyNDMyOTczOCwicGF0aCI6Ii8zMzc2OTU3LzMyNDM0NjA3NC03ZjNhMWIyYi03M2FkLTQwZmUtYjNjZC1hYTMzYTM5MGE2OTMucG5nP1gtQW16LUFsZ29yaXRobT1BV1M0LUhNQUMtU0hBMjU2JlgtQW16LUNyZWRlbnRpYWw9QUtJQVZDT0RZTFNBNTNQUUs0WkElMkYyMDI0MDgyMiUyRnVzLWVhc3QtMSUyRnMzJTJGYXdzNF9yZXF1ZXN0JlgtQW16LURhdGU9MjAyNDA4MjJUMTIyODU4WiZYLUFtei1FeHBpcmVzPTMwMCZYLUFtei1TaWduYXR1cmU9ZjU3ZGRjYzU2ODljZTc3YmViOTU2ZGNiODBmYTVkZDYzYjQ1MzNjM2NmM2FiMWM1MjhmY2VmNjc5ODAxZTE5MiZYLUFtei1TaWduZWRIZWFkZXJzPWhvc3QmYWN0b3JfaWQ9MCZrZXlfaWQ9MCZyZXBvX2lkPTAifQ.hpsqk_zQwmU83QoxWbTXkjo1Gha8cC4bpFMq7YfuKjc)
The problem seems to be that the autocomplete doesn’t have a chance to respond.
Also, this problem also seems to happen if someone has a slight misspelling.
The user’s goal is to enter an address, and to get meaningful feedback when there is an error so that the can re-try or make a correction.
Steps to reproduce the issue
What happens
You will see an error message that makes it look like we don’t have listings in that area, even if we actually do.
What's the expected result?
The accurate results for that address
Device configuration
The text was updated successfully, but these errors were encountered: