Skip to content

Commit

Permalink
cleaned up the formatting in selectAddressSuggestion
Browse files Browse the repository at this point in the history
  • Loading branch information
acatchpole committed Jan 23, 2024
1 parent a8f891d commit 8abc6a3
Showing 1 changed file with 4 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,6 @@ export default {
selectAddressSuggestion(suggestion) {
const ownerAddressArray = suggestion.split(',');
if(ownerAddressArray.length > 1){
const PROV_ARRAY_INDEX = ownerAddressArray.length -1;
const CITY_ARRAY_INDEX = ownerAddressArray.length -2;
const STREET_ARRAY_INDEX = ownerAddressArray.length -3;
Expand All @@ -231,11 +230,11 @@ export default {
this.ownerProvinceInput = this.codes.province_codes[0].province_state_code;
this.ownerAddressInput = '';
}
else {
else {
this.ownerProvinceInput = "";
}
this.ownerCityInput = ownerAddressArray[CITY_ARRAY_INDEX].trim();
if(ownerAddressArray[STREET_ARRAY_INDEX]) this.ownerAddressInput = ownerAddressArray[STREET_ARRAY_INDEX];
}
this.ownerCityInput = ownerAddressArray[CITY_ARRAY_INDEX].trim();
if(ownerAddressArray[STREET_ARRAY_INDEX]) this.ownerAddressInput = ownerAddressArray[STREET_ARRAY_INDEX];
}
this.clearAddressSuggestions();
},
Expand Down

0 comments on commit 8abc6a3

Please sign in to comment.